From 85e0f0b94c8099f6e43cf9e2f6f797b2b57cf98c Mon Sep 17 00:00:00 2001 From: Andrew Min Date: Mon, 4 Dec 2023 17:24:52 -0500 Subject: [PATCH] release v2023.12.0 --- api/public_api.swagger.json | 129 +++++++++++++++++++++++++++++++++++- 1 file changed, 127 insertions(+), 2 deletions(-) diff --git a/api/public_api.swagger.json b/api/public_api.swagger.json index 738061f..93edb2f 100644 --- a/api/public_api.swagger.json +++ b/api/public_api.swagger.json @@ -897,6 +897,32 @@ "tags": ["Policies"] } }, + "/public/v1/submit/email_auth": { + "post": { + "summary": "Email Auth", + "description": "Authenticate a user via Email", + "operationId": "EmailAuth", + "responses": { + "200": { + "description": "A successful response.", + "schema": { + "$ref": "#/definitions/ActivityResponse" + } + } + }, + "parameters": [ + { + "name": "body", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/EmailAuthRequest" + } + } + ], + "tags": ["Email Auth"] + } + }, "/public/v1/submit/export_private_key": { "post": { "summary": "Export Private Key", @@ -1482,7 +1508,8 @@ "ACTIVITY_TYPE_SIGN_TRANSACTION_V2", "ACTIVITY_TYPE_EXPORT_PRIVATE_KEY", "ACTIVITY_TYPE_EXPORT_WALLET", - "ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V4" + "ACTIVITY_TYPE_CREATE_SUB_ORGANIZATION_V4", + "ACTIVITY_TYPE_EMAIL_AUTH" ] }, "AddressFormat": { @@ -1515,6 +1542,11 @@ }, "updatedAt": { "$ref": "#/definitions/external.data.v1.Timestamp" + }, + "expirationSeconds": { + "type": "string", + "format": "uint64", + "description": "Optional window (in seconds) indicating how long the API Key should last." } }, "required": [ @@ -1535,6 +1567,10 @@ "publicKey": { "type": "string", "description": "The public component of a cryptographic key pair used to sign messages and transactions." + }, + "expirationSeconds": { + "type": "string", + "description": "Optional window (in seconds) indicating how long the API Key should last." } }, "required": ["apiKeyName", "publicKey"] @@ -2346,6 +2382,10 @@ "disableEmailRecovery": { "type": "boolean", "description": "Disable email recovery for the sub-organization" + }, + "disableEmailAuth": { + "type": "boolean", + "description": "Disable email auth for the sub-organization" } }, "required": ["subOrganizationName", "rootUsers", "rootQuorumThreshold"] @@ -2995,6 +3035,84 @@ "type": "string", "enum": ["EFFECT_ALLOW", "EFFECT_DENY"] }, + "EmailAuthIntent": { + "type": "object", + "properties": { + "email": { + "type": "string", + "description": "Email of the authenticating user." + }, + "targetPublicKey": { + "type": "string", + "description": "Client-side public key generated by the user, to which the email auth bundle (credentials) will be encrypted." + }, + "apiKeyName": { + "type": "string", + "description": "Optional human-readable name for an API Key. If none provided, default to Email Auth - \u003cTimestamp\u003e" + }, + "expirationSeconds": { + "type": "string", + "description": "Optional window (in seconds) indicating how long the API Key should last. Default to 30 minutes." + }, + "emailCustomization": { + "$ref": "#/definitions/EmailCustomization", + "description": "Optional parameters for customizing emails. If not provided, use defaults." + } + }, + "required": ["email", "targetPublicKey"] + }, + "EmailAuthRequest": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": ["ACTIVITY_TYPE_EMAIL_AUTH"] + }, + "timestampMs": { + "type": "string", + "description": "Timestamp (in milliseconds) of the request, used to verify liveness of user requests." + }, + "organizationId": { + "type": "string", + "description": "Unique identifier for a given Organization." + }, + "parameters": { + "$ref": "#/definitions/EmailAuthIntent" + } + }, + "required": ["type", "timestampMs", "organizationId", "parameters"] + }, + "EmailAuthResult": { + "type": "object", + "properties": { + "userId": { + "type": "string", + "description": "Unique identifier for the authenticating User." + }, + "apiKeyId": { + "type": "string", + "description": "Unique identifier for the created API key." + } + }, + "required": ["userId", "apiKeyId"] + }, + "EmailCustomization": { + "type": "object", + "properties": { + "subject": { + "type": "string" + }, + "body": { + "type": "string" + }, + "styling": { + "type": "string" + }, + "urlPrefix": { + "type": "string" + } + } + }, "ExportPrivateKeyIntent": { "type": "object", "properties": { @@ -3112,7 +3230,8 @@ "type": "string", "enum": [ "FEATURE_NAME_ROOT_USER_EMAIL_RECOVERY", - "FEATURE_NAME_WEBAUTHN_ORIGINS" + "FEATURE_NAME_WEBAUTHN_ORIGINS", + "FEATURE_NAME_EMAIL_AUTH" ] }, "GetActivitiesRequest": { @@ -3696,6 +3815,9 @@ }, "createSubOrganizationIntentV4": { "$ref": "#/definitions/CreateSubOrganizationIntentV4" + }, + "emailAuthIntent": { + "$ref": "#/definitions/EmailAuthIntent" } }, "required": ["createOrganizationIntent"] @@ -4270,6 +4392,9 @@ }, "createSubOrganizationResultV4": { "$ref": "#/definitions/CreateSubOrganizationResultV4" + }, + "emailAuthResult": { + "$ref": "#/definitions/EmailAuthResult" } } },