@turnkey/sdk-types 0.4.0 → 0.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @turnkey/sdk-types
2
2
 
3
+ ## 0.4.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [#958](https://github.com/tkhq/sdk/pull/958) [`5a96fe8`](https://github.com/tkhq/sdk/commit/5a96fe80db4c4c45e09ad8c613695ee4c2b8e51f) Author [@amircheikh](https://github.com/amircheikh) - - Synced api with mono
8
+
3
9
  ## 0.4.0
4
10
 
5
11
  ## 0.4.0-beta.6
@@ -148,6 +148,8 @@ export type v1Activity = {
148
148
  result: v1Result;
149
149
  /** A list of objects representing a particular User's approval or rejection of a Consensus request, including all relevant metadata. */
150
150
  votes: v1Vote[];
151
+ /** A list of app proofs generated by enclaves during activity execution, providing verifiable attestations of performed operations. */
152
+ appProofs?: v1AppProof[];
151
153
  /** An artifact verifying a User's action. */
152
154
  fingerprint: string;
153
155
  canApprove: boolean;
@@ -197,6 +199,16 @@ export type v1ApiOnlyUserParams = {
197
199
  /** A list of API Key parameters. This field, if not needed, should be an empty array in your request body. */
198
200
  apiKeys: apiApiKeyParams[];
199
201
  };
202
+ export type v1AppProof = {
203
+ /** Scheme of signing key. */
204
+ scheme: v1SignatureScheme;
205
+ /** Ephemeral public key. */
206
+ publicKey: string;
207
+ /** JSON serialized AppProofPayload. */
208
+ proofPayload: string;
209
+ /** Signature over hashed proof_payload. */
210
+ signature: string;
211
+ };
200
212
  export type v1ApproveActivityIntent = {
201
213
  /** An artifact verifying a User's action. */
202
214
  fingerprint: string;
@@ -1270,6 +1282,15 @@ export type v1GetApiKeysResponse = {
1270
1282
  /** A list of API keys. */
1271
1283
  apiKeys: v1ApiKey[];
1272
1284
  };
1285
+ export type v1GetAppProofsRequest = {
1286
+ /** Unique identifier for a given Organization. */
1287
+ organizationId: string;
1288
+ /** Unique identifier for a given activity. */
1289
+ activityId: string;
1290
+ };
1291
+ export type v1GetAppProofsResponse = {
1292
+ appProofs: v1AppProof[];
1293
+ };
1273
1294
  export type v1GetAttestationDocumentRequest = {
1274
1295
  /** Unique identifier for a given organization. */
1275
1296
  organizationId: string;
@@ -2076,6 +2097,8 @@ export type v1OtpLoginIntent = {
2076
2097
  expirationSeconds?: string;
2077
2098
  /** Invalidate all other previously generated Login API keys */
2078
2099
  invalidateExisting?: boolean;
2100
+ /** Optional signature associated with the public key passed into the verification step. This must be a hex-encoded ECDSA signature over the verification token. Only required if a public key was provided during the verification step. */
2101
+ clientSignature?: string;
2079
2102
  };
2080
2103
  export type v1OtpLoginRequest = {
2081
2104
  type: string;
@@ -2450,6 +2473,7 @@ export type v1SignTransactionRequest = {
2450
2473
  export type v1SignTransactionResult = {
2451
2474
  signedTransaction: string;
2452
2475
  };
2476
+ export type v1SignatureScheme = "SIGNATURE_SCHEME_EPHEMERAL_KEY_P256";
2453
2477
  export type v1SimpleClientExtensionResults = {
2454
2478
  appid?: boolean;
2455
2479
  appidExclude?: boolean;
@@ -2847,6 +2871,8 @@ export type v1VerifyOtpIntent = {
2847
2871
  otpCode: string;
2848
2872
  /** Expiration window (in seconds) indicating how long the verification token is valid for. If not provided, a default of 1 hour will be used. Maximum value is 86400 seconds (24 hours) */
2849
2873
  expirationSeconds?: string;
2874
+ /** Client-side public key generated by the user, which will be added to the JWT response and verified in subsequent requests via a client proof signature */
2875
+ publicKey?: string;
2850
2876
  };
2851
2877
  export type v1VerifyOtpRequest = {
2852
2878
  type: string;
@@ -3197,6 +3223,17 @@ export type TGetActivitiesBody = {
3197
3223
  export type TGetActivitiesInput = {
3198
3224
  body: TGetActivitiesBody;
3199
3225
  };
3226
+ export type TGetAppProofsResponse = {
3227
+ appProofs: v1AppProof[];
3228
+ };
3229
+ export type TGetAppProofsBody = {
3230
+ organizationId?: string;
3231
+ /** Unique identifier for a given activity. */
3232
+ activityId: string;
3233
+ };
3234
+ export type TGetAppProofsInput = {
3235
+ body: TGetAppProofsBody;
3236
+ };
3200
3237
  export type TListOauth2CredentialsResponse = {
3201
3238
  oauth2Credentials: v1Oauth2Credential[];
3202
3239
  };
@@ -4281,6 +4318,8 @@ export type TOtpLoginBody = {
4281
4318
  expirationSeconds?: string;
4282
4319
  /** Invalidate all other previously generated Login API keys */
4283
4320
  invalidateExisting?: boolean;
4321
+ /** Optional signature associated with the public key passed into the verification step. This must be a hex-encoded ECDSA signature over the verification token. Only required if a public key was provided during the verification step. */
4322
+ clientSignature?: string;
4284
4323
  };
4285
4324
  export type TOtpLoginInput = {
4286
4325
  body: TOtpLoginBody;
@@ -4622,6 +4661,8 @@ export type TVerifyOtpBody = {
4622
4661
  otpCode: string;
4623
4662
  /** Expiration window (in seconds) indicating how long the verification token is valid for. If not provided, a default of 1 hour will be used. Maximum value is 86400 seconds (24 hours) */
4624
4663
  expirationSeconds?: string;
4664
+ /** Client-side public key generated by the user, which will be added to the JWT response and verified in subsequent requests via a client proof signature */
4665
+ publicKey?: string;
4625
4666
  };
4626
4667
  export type TVerifyOtpInput = {
4627
4668
  body: TVerifyOtpBody;
@@ -4712,6 +4753,8 @@ export type ProxyTOtpLoginBody = {
4712
4753
  publicKey: string;
4713
4754
  /** Invalidate all other previously generated Login API keys */
4714
4755
  invalidateExisting?: boolean;
4756
+ /** Optional signature associated with the public key passed into the verification step. This must be a hex-encoded ECDSA signature over the verification token. Only required if a public key was provided during the verification step. */
4757
+ clientSignature?: string;
4715
4758
  };
4716
4759
  export type ProxyTOtpLoginInput = {
4717
4760
  body: ProxyTOtpLoginBody;
@@ -4725,12 +4768,18 @@ export type ProxyTVerifyOtpBody = {
4725
4768
  otpId: string;
4726
4769
  /** OTP sent out to a user's contact (email or SMS) */
4727
4770
  otpCode: string;
4771
+ /** Client-side public key generated by the user, which will be added to the JWT response and verified in subsequent requests via a client proof signature */
4772
+ publicKey?: string;
4728
4773
  };
4729
4774
  export type ProxyTVerifyOtpInput = {
4730
4775
  body: ProxyTVerifyOtpBody;
4731
4776
  };
4732
4777
  export type ProxyTSignupResponse = {
4733
4778
  organizationId: string;
4779
+ /** Wallet created for the sub-organization, if provided in the request */
4780
+ wallet?: v1WalletResult;
4781
+ /** Root user ID created for this sub-organization */
4782
+ userId: string;
4734
4783
  };
4735
4784
  export type ProxyTSignupBody = {
4736
4785
  userEmail?: string;
@@ -4762,6 +4811,8 @@ export type ProxyTGetWalletKitConfigResponse = {
4762
4811
  oauthClientIds?: Record<string, any>;
4763
4812
  /** OAuth redirect URL to be used for social login flows. */
4764
4813
  oauthRedirectUrl?: string;
4814
+ otpAlphanumeric?: boolean;
4815
+ otpLength?: string;
4765
4816
  };
4766
4817
  export type ProxyTGetWalletKitConfigBody = {};
4767
4818
  export type ProxyTGetWalletKitConfigInput = {