@fairmint/canton-node-sdk
Version:
Canton Node SDK
121 lines • 11 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.LedgerJsonApiClient = void 0;
const core_1 = require("../../core");
const get_1 = require("./operations/v2/authenticated-user/get");
const submit_reassignment_1 = require("./operations/v2/commands/async/submit-reassignment");
const submit_1 = require("./operations/v2/commands/async/submit");
const completions_1 = require("./operations/v2/commands/completions");
const submit_and_wait_for_reassignment_1 = require("./operations/v2/commands/submit-and-wait-for-reassignment");
const submit_and_wait_for_transaction_tree_1 = require("./operations/v2/commands/submit-and-wait-for-transaction-tree");
const submit_and_wait_for_transaction_1 = require("./operations/v2/commands/submit-and-wait-for-transaction");
const submit_and_wait_1 = require("./operations/v2/commands/submit-and-wait");
const subscribe_to_completions_1 = require("./operations/v2/commands/subscribe-to-completions");
const get_events_by_contract_id_1 = require("./operations/v2/events/get-events-by-contract-id");
const delete_idp_1 = require("./operations/v2/idps/delete-idp");
const get_idp_1 = require("./operations/v2/idps/get-idp");
const get_2 = require("./operations/v2/idps/get");
const patch_idp_1 = require("./operations/v2/idps/patch-idp");
const post_1 = require("./operations/v2/idps/post");
const allocate_party_1 = require("./operations/v2/interactive-submission/allocate-party");
const create_user_1 = require("./operations/v2/interactive-submission/create-user");
const get_preferred_package_version_1 = require("./operations/v2/interactive-submission/get-preferred-package-version");
const get_preferred_packages_1 = require("./operations/v2/interactive-submission/get-preferred-packages");
const upload_dar_1 = require("./operations/v2/interactive-submission/upload-dar");
const get_package_status_1 = require("./operations/v2/packages/get-package-status");
const get_3 = require("./operations/v2/packages/get");
const post_2 = require("./operations/v2/packages/post");
const get_participant_id_1 = require("./operations/v2/parties/get-participant-id");
const get_party_details_1 = require("./operations/v2/parties/get-party-details");
const get_4 = require("./operations/v2/parties/get");
const post_3 = require("./operations/v2/parties/post");
const update_party_details_1 = require("./operations/v2/parties/update-party-details");
const get_active_contracts_1 = require("./operations/v2/state/get-active-contracts");
const get_connected_synchronizers_1 = require("./operations/v2/state/get-connected-synchronizers");
const get_latest_pruned_offsets_1 = require("./operations/v2/state/get-latest-pruned-offsets");
const get_ledger_end_1 = require("./operations/v2/state/get-ledger-end");
const subscribe_to_active_contracts_1 = require("./operations/v2/state/subscribe-to-active-contracts");
const get_flats_1 = require("./operations/v2/updates/get-flats");
const get_transaction_by_id_1 = require("./operations/v2/updates/get-transaction-by-id");
const get_transaction_by_offset_1 = require("./operations/v2/updates/get-transaction-by-offset");
const get_transaction_tree_by_id_1 = require("./operations/v2/updates/get-transaction-tree-by-id");
const get_transaction_tree_by_offset_1 = require("./operations/v2/updates/get-transaction-tree-by-offset");
const get_trees_1 = require("./operations/v2/updates/get-trees");
const get_update_by_id_1 = require("./operations/v2/updates/get-update-by-id");
const get_update_by_offset_1 = require("./operations/v2/updates/get-update-by-offset");
const subscribe_to_flats_1 = require("./operations/v2/updates/subscribe-to-flats");
const subscribe_to_trees_1 = require("./operations/v2/updates/subscribe-to-trees");
const create_user_2 = require("./operations/v2/users/create-user");
const delete_user_1 = require("./operations/v2/users/delete-user");
const get_user_1 = require("./operations/v2/users/get-user");
const grant_user_rights_1 = require("./operations/v2/users/grant-user-rights");
const list_user_rights_1 = require("./operations/v2/users/list-user-rights");
const list_users_1 = require("./operations/v2/users/list-users");
const revoke_user_rights_1 = require("./operations/v2/users/revoke-user-rights");
const update_user_identity_provider_1 = require("./operations/v2/users/update-user-identity-provider");
const update_user_1 = require("./operations/v2/users/update-user");
const get_5 = require("./operations/v2/version/get");
/** Client for interacting with Canton's LedgerJsonApi */
class LedgerJsonApiClient extends core_1.BaseClient {
constructor(clientConfig) {
super('LEDGER_JSON_API', clientConfig);
this.initializeMethods();
}
initializeMethods() {
this.getAuthenticatedUser = (params) => new get_1.GetAuthenticatedUser(this).execute(params);
this.asyncSubmitReassignment = (params) => new submit_reassignment_1.AsyncSubmitReassignment(this).execute(params);
this.asyncSubmit = (params) => new submit_1.AsyncSubmit(this).execute(params);
this.completions = (params) => new completions_1.Completions(this).execute(params);
this.submitAndWaitForReassignment = (params) => new submit_and_wait_for_reassignment_1.SubmitAndWaitForReassignment(this).execute(params);
this.submitAndWaitForTransactionTree = (params) => new submit_and_wait_for_transaction_tree_1.SubmitAndWaitForTransactionTree(this).execute(params);
this.submitAndWaitForTransaction = (params) => new submit_and_wait_for_transaction_1.SubmitAndWaitForTransaction(this).execute(params);
this.submitAndWait = (params) => new submit_and_wait_1.SubmitAndWait(this).execute(params);
this.subscribeToCompletions = (params, handlers) => new subscribe_to_completions_1.SubscribeToCompletions(this).subscribe(params, handlers);
this.getEventsByContractId = (params) => new get_events_by_contract_id_1.GetEventsByContractId(this).execute(params);
this.deleteIdentityProviderConfig = (params) => new delete_idp_1.DeleteIdentityProviderConfig(this).execute(params);
this.getIdentityProviderConfig = (params) => new get_idp_1.GetIdentityProviderConfig(this).execute(params);
this.listIdentityProviderConfigs = (params) => new get_2.ListIdentityProviderConfigs(this).execute(params);
this.updateIdentityProviderConfig = (params) => new patch_idp_1.UpdateIdentityProviderConfig(this).execute(params);
this.createIdentityProviderConfig = (params) => new post_1.CreateIdentityProviderConfig(this).execute(params);
this.interactiveSubmissionAllocateParty = (params) => new allocate_party_1.InteractiveSubmissionAllocateParty(this).execute(params);
this.interactiveSubmissionCreateUser = (params) => new create_user_1.InteractiveSubmissionCreateUser(this).execute(params);
this.interactiveSubmissionGetPreferredPackageVersion = (params) => new get_preferred_package_version_1.InteractiveSubmissionGetPreferredPackageVersion(this).execute(params);
this.interactiveSubmissionGetPreferredPackages = (params) => new get_preferred_packages_1.InteractiveSubmissionGetPreferredPackages(this).execute(params);
this.interactiveSubmissionUploadDar = (params) => new upload_dar_1.InteractiveSubmissionUploadDar(this).execute(params);
this.getPackageStatus = (params) => new get_package_status_1.GetPackageStatus(this).execute(params);
this.listPackages = () => new get_3.ListPackages(this).execute();
this.uploadDarFile = (params) => new post_2.UploadDarFile(this).execute(params);
this.getParticipantId = (params) => new get_participant_id_1.GetParticipantId(this).execute(params);
this.getPartyDetails = (params) => new get_party_details_1.GetPartyDetails(this).execute(params);
this.getParties = (params) => new get_4.GetParties(this).execute(params);
this.allocateParty = (params) => new post_3.AllocateParty(this).execute(params);
this.updatePartyDetails = (params) => new update_party_details_1.UpdatePartyDetails(this).execute(params);
this.getActiveContracts = (params) => new get_active_contracts_1.GetActiveContracts(this).execute(params);
this.getConnectedSynchronizers = (params) => new get_connected_synchronizers_1.GetConnectedSynchronizers(this).execute(params);
this.getLatestPrunedOffsets = (params) => new get_latest_pruned_offsets_1.GetLatestPrunedOffsets(this).execute(params);
this.getLedgerEnd = (params) => new get_ledger_end_1.GetLedgerEnd(this).execute(params);
this.subscribeToActiveContracts = (params, handlers) => new subscribe_to_active_contracts_1.SubscribeToActiveContracts(this).subscribe(params, handlers);
this.getUpdates = (params) => new get_flats_1.GetUpdates(this).execute(params);
this.getTransactionById = (params) => new get_transaction_by_id_1.GetTransactionById(this).execute(params);
this.getTransactionByOffset = (params) => new get_transaction_by_offset_1.GetTransactionByOffset(this).execute(params);
this.getTransactionTreeById = (params) => new get_transaction_tree_by_id_1.GetTransactionTreeById(this).execute(params);
this.getTransactionTreeByOffset = (params) => new get_transaction_tree_by_offset_1.GetTransactionTreeByOffset(this).execute(params);
this.getUpdateTrees = (params) => new get_trees_1.GetUpdateTrees(this).execute(params);
this.getUpdateById = (params) => new get_update_by_id_1.GetUpdateById(this).execute(params);
this.getUpdateByOffset = (params) => new get_update_by_offset_1.GetUpdateByOffset(this).execute(params);
this.subscribeToFlats = (params, handlers) => new subscribe_to_flats_1.SubscribeToFlats(this).subscribe(params, handlers);
this.subscribeToTrees = (params, handlers) => new subscribe_to_trees_1.SubscribeToTrees(this).subscribe(params, handlers);
this.createUser = (params) => new create_user_2.CreateUser(this).execute(params);
this.deleteUser = (params) => new delete_user_1.DeleteUser(this).execute(params);
this.getUser = (params) => new get_user_1.GetUser(this).execute(params);
this.grantUserRights = (params) => new grant_user_rights_1.GrantUserRights(this).execute(params);
this.listUserRights = (params) => new list_user_rights_1.ListUserRights(this).execute(params);
this.listUsers = (params) => new list_users_1.ListUsers(this).execute(params);
this.revokeUserRights = (params) => new revoke_user_rights_1.RevokeUserRights(this).execute(params);
this.updateUserIdentityProvider = (params) => new update_user_identity_provider_1.UpdateUserIdentityProvider(this).execute(params);
this.updateUser = (params) => new update_user_1.UpdateUser(this).execute(params);
this.getVersion = () => new get_5.GetVersion(this).execute();
}
}
exports.LedgerJsonApiClient = LedgerJsonApiClient;
//# sourceMappingURL=LedgerJsonApiClient.generated.js.map