@ledgerhq/coin-canton
Version:
57 lines • 1.25 kB
TypeScript
import { Account } from "@ledgerhq/types-live";
export declare enum OnboardStatus {
INIT = 0,
PREPARE = 1,
SIGN = 2,
SUBMIT = 3,
SUCCESS = 4,
ERROR = 5
}
export declare enum AuthorizeStatus {
INIT = 0,
PREPARE = 1,
SIGN = 2,
SUBMIT = 3,
SUCCESS = 4,
ERROR = 5
}
export type CantonOnboardProgress = {
status: OnboardStatus;
};
export type CantonOnboardResult = {
partyId: string;
account: Account;
};
export type CantonAuthorizeProgress = {
status: AuthorizeStatus;
};
export type CantonAuthorizeResult = {
isApproved: boolean;
};
/**
* Types for Canton Gateway Transaction API
* Based on the API endpoints in canton-gateway
*/
export interface PrepareTransactionRequest {
type: "transfer-pre-approval-proposal";
receiver: string;
}
export interface PrepareTransactionResponse {
serialized: string;
json: any;
hash: string;
}
export interface SubmitTransactionRequest {
serialized: string;
signature: string;
}
export interface SubmitTransactionResponse {
submission_id: string;
update_id: string;
}
export interface PreApprovalResult {
isApproved: boolean;
submissionId: string;
updateId: string;
}
//# sourceMappingURL=onboard.d.ts.map