From 9f0419b290c86c37d3c55507ef7a2866075f12d0 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 22 Nov 2026 06:10:54 +0000 Subject: [PATCH] chore: refresh store codegen snapshot --- packages/store/scripts/api-schema/schema.json | 18187 ++++++++++------ .../src/gateway/AUTO_GENERATED/.schema-hash | 2 +- .../src/gateway/AUTO_GENERATED/chains.ts | 3 + .../gateway/AUTO_GENERATED/collectibles.ts | 4 +- .../src/gateway/AUTO_GENERATED/community.ts | 4 +- .../src/gateway/AUTO_GENERATED/delegates.ts | 93 + .../src/gateway/AUTO_GENERATED/messages.ts | 43 +- .../gateway/AUTO_GENERATED/notifications.ts | 6 +- .../src/gateway/AUTO_GENERATED/portfolios.ts | 63 +- .../store/src/gateway/AUTO_GENERATED/relay.ts | 14 +- .../src/gateway/AUTO_GENERATED/safe-shield.ts | 1 + .../src/gateway/AUTO_GENERATED/spaces.ts | 262 +- .../src/gateway/AUTO_GENERATED/surveys.ts | 17 +- .../gateway/AUTO_GENERATED/transactions.ts | 111 +- 14 files changed, 11896 insertions(+), 6914 deletions(-) diff --git a/packages/store/scripts/api-schema/schema.json b/packages/store/scripts/api-schema/schema.json index c87e9026418..07c0a4fc6fb 100644 --- a/packages/store/scripts/api-schema/schema.json +++ b/packages/store/scripts/api-schema/schema.json @@ -434,6 +434,32 @@ ] } }, + "/v1/billing/trial-plans": { + "get": { + "description": "The general trial payment links a space that does not exist yet is offered: the standard trial, no negotiated links. Same shape as the payment links of a space.", + "operationId": "billingGetTrialPlansV1", + "parameters": [], + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PaymentLink" + } + } + } + } + } + }, + "summary": "Get the trial plans for a new space", + "tags": [ + "billing" + ] + } + }, "/v1/billing/plans/{planId}": { "get": { "operationId": "billingGetPlanV1", @@ -498,6 +524,9 @@ } } } + }, + "403": { + "description": "Not an admin" } }, "summary": "Get the billing portal session URL for a space", @@ -584,6 +613,12 @@ } } } + }, + "403": { + "description": "Not an admin, or a payment link this workspace is not offered" + }, + "409": { + "description": "This plan doesn't offer enough Safe seats for the workspace's current Safes" } }, "summary": "Create a checkout session for a payment link", @@ -592,6 +627,137 @@ ] } }, + "/v1/billing/spaces/{spaceId}/subscriptions/{subscriptionId}/preview-update": { + "get": { + "operationId": "billingPreviewSubscriptionUpdateV1", + "parameters": [ + { + "name": "subscriptionId", + "required": true, + "in": "path", + "description": "Subscription identifier", + "schema": { + "type": "string" + } + }, + { + "name": "planId", + "required": true, + "in": "query", + "description": "The price id of the plan to preview", + "schema": { + "type": "string" + } + }, + { + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SubscriptionUpdatePreview" + } + } + } + }, + "403": { + "description": "Not an admin, or a plan this workspace is not offered" + }, + "404": { + "description": "Subscription not found" + }, + "409": { + "description": "Already on this plan" + }, + "422": { + "description": "Malformed subscriptionId or planId" + } + }, + "summary": "Preview what moving a subscription to another plan would cost", + "tags": [ + "billing" + ] + } + }, + "/v1/billing/spaces/{spaceId}/subscriptions/{subscriptionId}": { + "patch": { + "description": "Safes in `removedSafes` are removed from the workspace first, then the plan changes. If the plan change fails after that, the answer is 502 and sending the same request again finishes it.", + "operationId": "billingUpdateSubscriptionV1", + "parameters": [ + { + "name": "subscriptionId", + "required": true, + "in": "path", + "description": "Subscription identifier", + "schema": { + "type": "string" + } + }, + { + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UpdateSubscriptionDto" + } + } + } + }, + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UpdateSubscriptionResult" + } + } + } + }, + "403": { + "description": "Not an admin, a plan this workspace is not offered, or a named paymentLinkId this workspace is not offered" + }, + "404": { + "description": "Subscription not found" + }, + "409": { + "description": "One of:\n- Already on this plan\n- The subscription is not in an updatable state\n- Several offered links sell the plan and none was named\n- The target plan doesn't offer enough Safe seats for the workspace's current Safes" + }, + "422": { + "description": "The named payment link does not offer this plan" + }, + "502": { + "description": "The billing service reported the plan change as unsuccessful, or failed after `removedSafes` were removed" + } + }, + "summary": "Move a subscription onto another plan", + "tags": [ + "billing" + ] + } + }, "/v1/billing/sessions/{sessionId}": { "get": { "operationId": "billingGetCheckoutSessionV1", @@ -775,22 +941,41 @@ ] }, "delete": { - "description": "Clears all cached Zerion portfolio data (overview, portfolio, positions) for a specific address", + "description": "Clears all cached Zerion portfolio data (overview, portfolio, positions) for a Safe. Repeat clears for the same Safe within a short cooldown are skipped.", "operationId": "portfolioClearPortfolioV1", "parameters": [ { "name": "address", "required": true, "in": "path", - "description": "Wallet address (0x prefixed hex string)", + "description": "Safe address (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "chainId", + "required": true, + "in": "query", + "description": "A chain on which the address is a Safe", "schema": { + "example": "1", "type": "string" } } ], "responses": { "204": { - "description": "" + "description": "Cleared, or skipped within cooldown" + }, + "404": { + "description": "The address is not a Safe on chainId" + }, + "422": { + "description": "Invalid address or chainId" + }, + "429": { + "description": "Rate limit reached" } }, "summary": "Clear portfolio cache", @@ -799,6 +984,72 @@ ] } }, + "/v2/portfolio/summaries": { + "get": { + "description": "Returns the fiat value of each Safe, summed from the cached Zerion snapshot that GET /v1/portfolio serves (one /positions call per wallet and environment) on Zerion-supported chains, and from the Transaction Service elsewhere. Safes that cannot be resolved, or that no source can value, are left out of the response.", + "operationId": "portfolioSummariesGetSummariesV2", + "parameters": [ + { + "name": "safes", + "required": true, + "in": "query", + "description": "Comma-separated list of Safe addresses in chainId:address format. Only the first MAX_SAFE_OVERVIEWS distinct entries are used.", + "schema": { + "example": "1:0x1234567890123456789012345678901234567890,137:0xabcdefabcdefabcdefabcdefabcdefabcdefabcd", + "type": "string" + } + }, + { + "name": "currency", + "required": true, + "in": "query", + "description": "Fiat currency code, any case (e.g. USD, eur)", + "schema": { + "example": "USD", + "type": "string" + } + }, + { + "name": "trusted", + "required": false, + "in": "query", + "description": "If true, only trusted tokens count. Defaults to true, like GET /v1/portfolio, so the totals match the Assets page.", + "schema": { + "example": true, + "type": "boolean" + } + } + ], + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PortfolioSummary" + } + } + } + } + }, + "400": { + "description": "Unsupported currency" + }, + "422": { + "description": "Invalid query parameters" + }, + "429": { + "description": "Rate limit reached" + } + }, + "summary": "Get portfolio summaries", + "tags": [ + "portfolio" + ] + } + }, "/v1/chains": { "get": { "description": "Retrieves a paginated list of all blockchain networks supported by the Safe infrastructure, including their configuration and capabilities.", @@ -824,6 +1075,9 @@ } } } + }, + "422": { + "description": "Invalid cursor" } }, "summary": "Get supported chains", @@ -1072,6 +1326,9 @@ } } } + }, + "422": { + "description": "Invalid cursor" } }, "summary": "Get supported chains (v2)", @@ -1145,15 +1402,15 @@ } }, { - "name": "trusted", + "name": "cursor", "required": false, "in": "query", "schema": { - "type": "boolean" + "type": "string" } }, { - "name": "exclude_spam", + "name": "trusted", "required": false, "in": "query", "schema": { @@ -1161,11 +1418,11 @@ } }, { - "name": "cursor", + "name": "exclude_spam", "required": false, "in": "query", "schema": { - "type": "string" + "type": "boolean" } } ], @@ -1179,6 +1436,9 @@ } } } + }, + "422": { + "description": "Invalid cursor" } }, "tags": [ @@ -1209,6 +1469,9 @@ } } } + }, + "422": { + "description": "Invalid cursor" } }, "tags": [ @@ -1259,7 +1522,7 @@ } }, { - "name": "holder", + "name": "cursor", "required": false, "in": "query", "schema": { @@ -1267,7 +1530,7 @@ } }, { - "name": "cursor", + "name": "holder", "required": false, "in": "query", "schema": { @@ -1276,8 +1539,8 @@ } ], "responses": { - "200": { - "description": "" + "422": { + "description": "Invalid cursor" } }, "tags": [ @@ -1316,6 +1579,9 @@ } } } + }, + "422": { + "description": "Invalid cursor" } }, "tags": [ @@ -1415,6 +1681,9 @@ } } } + }, + "422": { + "description": "Invalid cursor" } }, "tags": [ @@ -1483,6 +1752,9 @@ } } } + }, + "422": { + "description": "Invalid cursor" } }, "tags": [ @@ -1750,6 +2022,9 @@ } } } + }, + "422": { + "description": "Invalid cursor" } }, "summary": "Get supported gas tokens", @@ -1853,6 +2128,9 @@ }, "404": { "description": "Message not found" + }, + "422": { + "description": "Invalid chainId or messageHash" } }, "summary": "Get message by hash", @@ -1908,6 +2186,9 @@ }, "404": { "description": "Safe not found on the specified chain" + }, + "422": { + "description": "Invalid chainId, safeAddress or cursor" } }, "summary": "Get messages for Safe", @@ -1955,7 +2236,10 @@ "description": "Message accepted. The Transaction Service indexes messages asynchronously, so the message may not be immediately retrievable — poll GET /v1/chains/{chainId}/messages/{messageHash}." }, "400": { - "description": "Invalid message format or signature" + "description": "Invalid message format" + }, + "422": { + "description": "Invalid chainId, safeAddress, request body or signature" } }, "summary": "Create message", @@ -2005,10 +2289,13 @@ "description": "Signature added successfully" }, "400": { - "description": "Invalid signature or signer not authorized" + "description": "Rejected by the upstream service" }, "404": { "description": "Message not found" + }, + "422": { + "description": "Invalid chainId, messageHash, request body or signature" } }, "summary": "Add message signature", @@ -2058,6 +2345,9 @@ }, "404": { "description": "User not found - the authenticated wallet is not associated with any user" + }, + "409": { + "description": "User is the last admin of at least one workspace - promote another admin or delete the workspace first" } }, "summary": "Delete user", @@ -2175,7 +2465,7 @@ }, "/v1/spaces/{spaceId}/address-book": { "get": { - "description": "Retrieves all address book entries for a specific space. Address books help organize and label frequently used addresses.", + "description": "Retrieves all address book entries for a specific space, with the tags of each entry and every tag of the space. Address books help organize and label frequently used addresses.", "operationId": "addressBooksGetAddressBookItemsV1", "parameters": [ { @@ -2207,10 +2497,10 @@ "description": "Authentication required - valid JWT token must be provided" }, "403": { - "description": "Access forbidden - user is not a member of this space" + "description": "Access forbidden - user is not an active member of this space" }, "404": { - "description": "User, member, or space not found" + "description": "Space not found" } }, "summary": "Get space address book", @@ -2219,7 +2509,7 @@ ] }, "put": { - "description": "Creates or updates address book entries for a space. This allows adding labels and organizing frequently used addresses.", + "description": "Creates or updates address book entries for a space. This allows adding labels and organizing frequently used addresses. An entry that carries tags gets exactly those tags; an entry without tags keeps its current tags.", "operationId": "addressBooksUpsertAddressBookItemsV1", "parameters": [ { @@ -2256,16 +2546,19 @@ } }, "400": { - "description": "Address book items limit exceeded or invalid data provided" + "description": "Invalid space identifier, address book items limit exceeded, or space tag limit reached" }, "401": { "description": "Authentication required - valid JWT token must be provided" }, "403": { - "description": "Access forbidden - user is not authorized to modify this address book" + "description": "Access forbidden - user is not an active admin of this space" }, "404": { - "description": "User, member, or space not found" + "description": "Space not found" + }, + "422": { + "description": "Invalid body - an invalid address, name or chain ID, an invalid tag name, or more tags on an entry than allowed" } }, "summary": "Update space address book", @@ -2274,8 +2567,256 @@ ] } }, - "/v1/spaces/{spaceId}/address-book/{address}": { - "delete": { + "/v1/spaces/{spaceId}/address-book/tags": { + "put": { + "description": "Replaces the tags of one or more address book entries. Any active member of the space may set tags. A tag name the space does not have yet creates the tag. The request is all or nothing: if one entry cannot be tagged, no entry changes.", + "operationId": "addressBooksSetContactTagsV1", + "parameters": [ + { + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID containing the address book", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "description": "The entries to tag, each with its full set of tag names", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SetContactTagsDto" + } + } + } + }, + "responses": { + "200": { + "description": "Tags set successfully", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SpaceAddressBookDto" + } + } + } + }, + "400": { + "description": "Invalid space identifier, the space tag limit is reached, or more entries than the address book can hold" + }, + "401": { + "description": "Authentication required - valid JWT token must be provided" + }, + "403": { + "description": "Access forbidden - user is not an active member of this space" + }, + "404": { + "description": "Space not found, or an address is not in the address book" + }, + "422": { + "description": "Invalid body - no entries, an address listed twice, an invalid address or tag name, or more tags on an entry than allowed" + }, + "429": { + "description": "Rate limit exceeded" + } + }, + "summary": "Set address book entry tags", + "tags": [ + "spaces" + ] + }, + "post": { + "description": "Creates a tag of the space with no contacts, in a random unused colour. Any active member of the space may create tags.", + "operationId": "addressBooksCreateTagV1", + "parameters": [ + { + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID containing the address book", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "description": "The tag name", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateTagDto" + } + } + } + }, + "responses": { + "201": { + "description": "Tag created successfully", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SpaceAddressBookDto" + } + } + } + }, + "400": { + "description": "Invalid space identifier, or the space already has 8 tags" + }, + "401": { + "description": "Authentication required - valid JWT token must be provided" + }, + "403": { + "description": "Access forbidden - user is not an active member of this space" + }, + "404": { + "description": "Space not found" + }, + "409": { + "description": "The space has a tag with this name, ignoring case" + }, + "422": { + "description": "Invalid tag name" + }, + "429": { + "description": "Rate limit exceeded" + } + }, + "summary": "Create address book tag", + "tags": [ + "spaces" + ] + } + }, + "/v1/spaces/{spaceId}/address-book/tags/{tagId}": { + "patch": { + "description": "Renames a tag of the space; the tag keeps its colour. Renaming to the name of another tag of the space merges the two: the entries of the renamed tag move to the existing tag, which keeps its name and colour. Any active member of the space may rename tags.", + "operationId": "addressBooksRenameTagV1", + "parameters": [ + { + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID containing the address book", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + }, + { + "name": "tagId", + "required": true, + "in": "path", + "description": "ID of the tag to rename", + "schema": { + "type": "number" + } + } + ], + "requestBody": { + "required": true, + "description": "The new tag name", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RenameTagDto" + } + } + } + }, + "responses": { + "200": { + "description": "Tag renamed successfully", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SpaceAddressBookDto" + } + } + } + }, + "400": { + "description": "Invalid space or tag identifier" + }, + "401": { + "description": "Authentication required - valid JWT token must be provided" + }, + "403": { + "description": "Access forbidden - user is not an active member of this space" + }, + "404": { + "description": "Space not found, or the tag is not a tag of this space" + }, + "422": { + "description": "Invalid tag name, or a tag identifier beyond the safe integer range" + }, + "429": { + "description": "Rate limit exceeded" + } + }, + "summary": "Rename address book tag", + "tags": [ + "spaces" + ] + }, + "delete": { + "description": "Deletes a tag of the space and removes it from every address book entry. Any active member of the space may delete tags.", + "operationId": "addressBooksDeleteTagV1", + "parameters": [ + { + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID containing the address book", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + }, + { + "name": "tagId", + "required": true, + "in": "path", + "description": "ID of the tag to delete", + "schema": { + "type": "number" + } + } + ], + "responses": { + "204": { + "description": "Tag deleted successfully" + }, + "400": { + "description": "Invalid space or tag identifier" + }, + "401": { + "description": "Authentication required - valid JWT token must be provided" + }, + "403": { + "description": "Access forbidden - user is not an active member of this space" + }, + "404": { + "description": "Space not found, or the tag is not a tag of this space" + }, + "422": { + "description": "A tag identifier beyond the safe integer range" + } + }, + "summary": "Delete address book tag", + "tags": [ + "spaces" + ] + } + }, + "/v1/spaces/{spaceId}/address-book/{address}": { + "delete": { "description": "Removes a specific address from the space address book by its address.", "operationId": "addressBooksDeleteByAddressV1", "parameters": [ @@ -2307,10 +2848,10 @@ "description": "Invalid space identifier" }, "403": { - "description": "Access forbidden - user is not authorized to modify this address book" + "description": "Access forbidden - user is not an active admin of this space" }, "404": { - "description": "User, member, space, or address book entry not found" + "description": "Space not found" } }, "summary": "Delete address book entry", @@ -2577,67 +3118,227 @@ ] } }, - "/v1/spaces/{id}": { - "get": { - "description": "Retrieves detailed information about a specific space. The user must be a member of or invited to the space.", - "operationId": "spacesGetOneV1", - "parameters": [ - { - "name": "id", - "required": true, - "in": "path", - "description": "Space UUID", - "schema": { - "example": "123e4567-e89b-12d3-a456-426614174000", - "type": "string" + "/v1/spaces/setup": { + "post": { + "description": "Creates the space and its creator, stores the rest of the form as a pending setup, and starts the trial checkout. The setup (Safes, contacts, invites, survey) is applied when the trial starts. Without a plan (paymentLinkId null), the setup is applied at once and checkoutUrl is null.", + "operationId": "spacesCreateSetupV1", + "parameters": [], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateSpaceSetupDto" + } } } - ], + }, "responses": { - "200": { - "description": "Space information retrieved successfully", + "201": { + "description": "", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/GetSpaceResponse" + "$ref": "#/components/schemas/SpaceSetupCheckoutDto" } } } }, "400": { - "description": "Invalid space identifier" + "description": "Invalid return URL or survey selections" }, "401": { "description": "Authentication required - valid JWT token must be provided" }, "403": { - "description": "Forbidden resource - user is not a member of this space" + "description": "A plan that is not offered, or the space limit is reached" }, "404": { - "description": "Space not found" + "description": "No active survey for this slug" + }, + "409": { + "description": "The plan has fewer Safe seats than selected, or too many invites" + }, + "422": { + "description": "Invalid body, a plan while billing is not available, or no plan while billing is enforced" + }, + "502": { + "description": "The space was created, but the checkout could not start. The body carries spaceId; retry with PUT." } }, - "summary": "Get space by UUID", + "summary": "Create a space from the onboarding form", "tags": [ "spaces" ] - }, - "patch": { - "description": "Updates space information such as name. Only space admins can update space details.", - "operationId": "spacesUpdateV1", + } + }, + "/v1/spaces/{id}/setup": { + "get": { + "description": "Returns the onboarding form stored for the space. While it is pending, the subscription is read from the billing service, and a started trial applies the setup before this answers. Admins only.", + "operationId": "spacesGetSetupV1", "parameters": [ { "name": "id", "required": true, "in": "path", - "description": "Space UUID to update", + "description": "Space UUID", "schema": { "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } } ], - "requestBody": { + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SpaceSetupDto" + } + } + } + }, + "400": { + "description": "Invalid space identifier" + }, + "401": { + "description": "Authentication required - valid JWT token must be provided" + }, + "403": { + "description": "User is not an admin of this space" + }, + "404": { + "description": "Space not found, or it has no setup" + } + }, + "summary": "Get the setup of a space", + "tags": [ + "spaces" + ] + }, + "put": { + "description": "Replaces the name and the onboarding form of a space whose trial has not started, and starts a new checkout. Admins only.", + "operationId": "spacesUpdateSetupV1", + "parameters": [ + { + "name": "id", + "required": true, + "in": "path", + "description": "Space UUID", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateSpaceSetupDto" + } + } + } + }, + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SpaceSetupCheckoutDto" + } + } + } + }, + "400": { + "description": "Invalid space identifier, return URL or survey selections" + }, + "401": { + "description": "Authentication required - valid JWT token must be provided" + }, + "403": { + "description": "Elevation required, not an admin, or a plan that is not offered" + }, + "404": { + "description": "Space not found, it has no setup, or no active survey" + }, + "409": { + "description": "The setup is applied or the trial has started, the plan has fewer Safe seats than selected, or too many invites" + }, + "422": { + "description": "Invalid body, a plan while billing is not available, or no plan while billing is enforced" + } + }, + "summary": "Replace the setup of a space", + "tags": [ + "spaces" + ] + } + }, + "/v1/spaces/{id}": { + "get": { + "description": "Retrieves detailed information about a specific space. The user must be a member of or invited to the space.", + "operationId": "spacesGetOneV1", + "parameters": [ + { + "name": "id", + "required": true, + "in": "path", + "description": "Space UUID", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "Space information retrieved successfully", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/GetSpaceResponse" + } + } + } + }, + "400": { + "description": "Invalid space identifier" + }, + "401": { + "description": "Authentication required - valid JWT token must be provided" + }, + "403": { + "description": "Forbidden resource - user is not a member of this space" + }, + "404": { + "description": "Space not found" + } + }, + "summary": "Get space by UUID", + "tags": [ + "spaces" + ] + }, + "patch": { + "description": "Updates space information such as name. Only space admins can update space details.", + "operationId": "spacesUpdateV1", + "parameters": [ + { + "name": "id", + "required": true, + "in": "path", + "description": "Space UUID to update", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + } + ], + "requestBody": { "required": true, "description": "Space update data including new name or other properties", "content": { @@ -2730,6 +3431,15 @@ "type": "string" } }, + { + "name": "cursor", + "required": false, + "in": "query", + "description": "Pagination cursor for retrieving the next set of results", + "schema": { + "type": "string" + } + }, { "name": "event_type", "required": false, @@ -2778,15 +3488,6 @@ ], "type": "string" } - }, - { - "name": "cursor", - "required": false, - "in": "query", - "description": "Pagination cursor for retrieving the next set of results", - "schema": { - "type": "string" - } } ], "responses": { @@ -2808,6 +3509,9 @@ }, "403": { "description": "User is not an ACTIVE member of the space, or the feature is disabled" + }, + "422": { + "description": "Invalid cursor" } }, "summary": "Get space audit log", @@ -3007,6 +3711,38 @@ ] } }, + "/v1/spaces/safes": { + "get": { + "description": "Retrieves the Safes of every space the user is an active member of, one entry per space with its Safes grouped by chain like the per-space endpoint. A space without Safes has an empty `safes` object.", + "operationId": "spaceSafesGetAllV1", + "parameters": [], + "responses": { + "200": { + "description": "Safes of all spaces retrieved successfully", + "content": { + "application/json": { + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/GetSpacesSafesResponse" + } + } + } + } + }, + "401": { + "description": "Authentication required" + }, + "403": { + "description": "Access forbidden - missing or invalid authentication" + } + }, + "summary": "Get Safes of all spaces", + "tags": [ + "spaces" + ] + } + }, "/v1/spaces/{spaceId}/members/invite": { "post": { "description": "Invites one or more users to join a space. Only space admins can send invitations.", @@ -3204,6 +3940,9 @@ }, "409": { "description": "Invitation is not in a pending state" + }, + "429": { + "description": "Invitation was renewed recently" } }, "summary": "Renew space invitation", @@ -3626,38 +4365,55 @@ ] } }, - "/v1/spaces/{spaceId}/surveys/{slug}/state": { + "/v1/spaces/{spaceId}/chains/{chainId}/security/{safeAddress}/recipient/{recipientAddress}": { "get": { - "description": "Returns the active survey definition and this space's response (if any) in a single round trip. Only active admins of the space can read survey state.", - "operationId": "surveysGetStateV1", + "description": "Performs real-time security analysis of a recipient address for a Safe registered to a Space, gated by the copilot_scans plan entitlement.", + "operationId": "spaceSafeShieldAnalyzeRecipientV1", "parameters": [ { - "name": "spaceId", + "name": "chainId", "required": true, "in": "path", - "description": "Space UUID to get survey state for", + "description": "Chain ID where the Safe is deployed", "schema": { - "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } }, { - "name": "slug", + "name": "safeAddress", "required": true, "in": "path", + "description": "Safe contract address, must be registered to the Space", + "schema": { + "type": "string" + } + }, + { + "name": "recipientAddress", + "required": true, + "in": "path", + "description": "Recipient address to analyze", + "schema": { + "type": "string" + } + }, + { + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID", "schema": { - "example": "onboarding", "type": "string" } } ], "responses": { "200": { - "description": "", + "description": "Recipient interaction analysis results", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SurveyStateDto" + "$ref": "#/components/schemas/SingleRecipientAnalysisDto" } } } @@ -3666,109 +4422,199 @@ "description": "Invalid space identifier" }, "401": { - "description": "Not authenticated" + "description": "Authentication required" }, - "403": { - "description": "User is not an active admin of this space" + "402": { + "description": "The Space has no copilot_scans entitlement. The body carries `{ code: \"FEATURE_NOT_GRANTED\", feature }`" }, - "404": { - "description": "No active survey for this slug" + "403": { + "description": "Not a member of this Space, or the Safe is not registered to it" } }, - "summary": "Get survey state for a space", + "summary": "Analyze recipient address on a Space", "tags": [ - "surveys" + "safe-shield" ] } }, - "/v1/spaces/{spaceId}/surveys/{slug}/responses": { + "/v1/spaces/{spaceId}/chains/{chainId}/security/{safeAddress}/counterparty-analysis": { "post": { - "description": "Submits or updates the space's response to the active survey for the given slug. Only active admins of the space can submit. Idempotent: repeat submissions overwrite the previous response.", - "operationId": "surveysSubmitResponseV1", + "description": "Performs combined contract and recipient analysis for a Safe transaction on a Safe registered to a Space, gated by the copilot_scans plan entitlement.", + "operationId": "spaceSafeShieldAnalyzeCounterpartyV1", "parameters": [ { - "name": "spaceId", + "name": "chainId", "required": true, "in": "path", - "description": "Space UUID to submit a survey response for", + "description": "Chain ID where the Safe is deployed", "schema": { - "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } }, { - "name": "slug", + "name": "safeAddress", "required": true, "in": "path", + "description": "Safe contract address, must be registered to the Space", + "schema": { + "type": "string" + } + }, + { + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID", "schema": { - "example": "onboarding", "type": "string" } } ], "requestBody": { "required": true, + "description": "Transaction data used to analyze all counterparties involved.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SubmitSurveyResponseDto" + "$ref": "#/components/schemas/CounterpartyAnalysisRequestDto" } } } }, "responses": { - "201": { - "description": "", + "200": { + "description": "Combined counterparty analysis including recipients and contracts grouped by status group and mapped to an address.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SurveyResponseResultDto" + "$ref": "#/components/schemas/CounterpartyAnalysisDto" } } } }, "400": { - "description": "Empty selections or unknown option keys" + "description": "Invalid space identifier" }, "401": { - "description": "Not authenticated" + "description": "Authentication required" }, - "403": { - "description": "User is not an active admin of this space" + "402": { + "description": "The Space has no copilot_scans entitlement. The body carries `{ code: \"FEATURE_NOT_GRANTED\", feature }`" }, - "404": { - "description": "No active survey for this slug" + "403": { + "description": "Not a member of this Space, or the Safe is not registered to it" } }, - "summary": "Submit a survey response for a space", + "summary": "Analyze transaction counterparties on a Space", "tags": [ - "surveys" + "safe-shield" ] } }, - "/v1/spaces/{spaceId}/entitlements": { + "/v1/spaces/{spaceId}/transactions/queued": { "get": { - "description": "The single source of truth for what a workspace can do: the active plan and per-feature entitlements, with quotas and usage for metered ones. Free-tier workspaces get the same contract shape.", - "operationId": "entitlementsGetEntitlementsV1", + "description": "Retrieves the pending transactions of every Safe in a Space, across chains, in nonce order. Results are keyed by Safe address and then by chain ID. The queue is read up to a maximum number of queue service pages; `count` is the size of the whole queue. The filters narrow `results`; `counts` are faceted, each applying every filter but its own. A matching transaction is returned with the rest of its conflict group and its label.", + "operationId": "spaceTransactionsGetTransactionQueueV1", "parameters": [ + { + "name": "status", + "required": false, + "in": "query", + "description": "Keep the transactions with one of these statuses, comma-separated. `sign` is a transaction one of the caller wallets still has to sign.", + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "example": "sign,execute" + } + }, + { + "name": "safes", + "required": false, + "in": "query", + "description": "Keep the transactions of these Safes, comma-separated as `{chainId}:{safeAddress}`", + "schema": { + "example": "11155111:0x0000000000000000000000000000000000000000", + "type": "string" + } + }, + { + "name": "chainIds", + "required": false, + "in": "query", + "description": "Keep the transactions on these chains, comma-separated", + "schema": { + "example": "1,137", + "type": "string" + } + }, + { + "name": "signers", + "required": false, + "in": "query", + "description": "Keep the transactions still awaiting a signature from one of these addresses, comma-separated", + "schema": { + "example": "0x0000000000000000000000000000000000000000", + "type": "string" + } + }, + { + "name": "conflicting", + "required": false, + "in": "query", + "description": "Keep the transactions sharing their nonce with another", + "schema": { + "type": "boolean" + } + }, + { + "name": "stale", + "required": false, + "in": "query", + "description": "Keep the transactions proposed more than 7 days ago", + "schema": { + "type": "boolean" + } + }, + { + "name": "search", + "required": false, + "in": "query", + "description": "Keep the transactions whose Safe (address or Space address book name), network name, status, or a signer still to sign (address or name) contains this text, ignoring case. Unlike the filters, it narrows every count. At most 100 characters.", + "schema": { + "example": "treasury", + "type": "string" + } + }, + { + "name": "limit", + "required": false, + "in": "query", + "description": "Return only the first transactions of the queue, by nonce across every Safe (not by age), up to the transactions an unlimited request returns. Without a filter or `search`, only that many are read: `counts` cover only those, and a conflict group cut by the limit is returned in part. With a filter or `search`, the whole queue is read and filtered first, so `counts` cover the whole queue and a conflict group is kept whole, which can return a few more than `limit`. `count` is always the size of the whole queue.", + "schema": { + "minimum": 1, + "example": 4, + "type": "number" + } + }, { "name": "spaceId", "required": true, "in": "path", "description": "Space UUID", "schema": { - "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } } ], "responses": { "200": { - "description": "", + "description": "Queue of the Safes in the Space", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/EntitlementsResponse" + "$ref": "#/components/schemas/SpaceQueuedItemPage" } } } @@ -3780,607 +4626,765 @@ "description": "Authentication required" }, "403": { - "description": "Access forbidden - user is not a member of this space" + "description": "Not a member of this Space" }, "404": { "description": "Space not found" + }, + "422": { + "description": "Unknown status, invalid CAIP-10 address, chain ID or signer address, non-boolean flag, too long search or invalid limit" } }, - "summary": "Get space entitlements", + "summary": "Get the transaction queue of a Space", "tags": [ - "entitlements" + "transactions" ] } }, - "/v1/chains/{chainId}/owners/{ownerAddress}/safes": { - "get": { - "description": "Retrieves a list of Safe addresses that are owned by the specified address on a specific chain.", - "operationId": "ownersGetSafesByOwnerV1", + "/v1/spaces/{spaceId}/chains/{chainId}/safes/{safeAddress}/policies/requests": { + "post": { + "description": "Stores the `Configuration[]` behind a `requestConfiguration(root)`, which publishes only the hash on-chain, so that the configurations a later `applyConfiguration` needs survive the delay. Call it before requesting the configuration on-chain: the root is recomputed from the configurations and has to match, but it is not required to exist on-chain yet. Idempotent: storing the same root again is a no-op.", + "operationId": "policiesCreateConfigurationRequestV1", "parameters": [ + { + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID the Safe belongs to", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + }, { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID to search for Safes", + "description": "Chain ID where the Safe is deployed", "schema": { - "example": "1", + "example": "11155111", "type": "string" } }, { - "name": "ownerAddress", + "name": "safeAddress", "required": true, "in": "path", - "description": "Owner address to search Safes for (0x prefixed hex string)", + "description": "Safe contract address, must be registered to the Space", "schema": { "type": "string" } } ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreatePolicyConfigurationRequestDto" + } + } + } + }, "responses": { - "200": { - "description": "List of Safes owned by the specified address", + "201": { + "description": "", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SafeList" + "$ref": "#/components/schemas/CreatePolicyConfigurationRequestResponse" } } } + }, + "400": { + "description": "Invalid space identifier, or the Safe holds the maximum number of active requests in this space" + }, + "401": { + "description": "Authentication required" + }, + "403": { + "description": "Access forbidden - user is not a member of this space, or the Safe is not in it" + }, + "422": { + "description": "Invalid chain ID, Safe address or body, the configurations do not hash to the given root, the chain has no policy engine, or a policy is neither a known policy contract on the chain nor the zero address" } }, - "summary": "Get Safes by owner", + "summary": "Store the configurations of a delayed configuration request", "tags": [ - "owners" + "spaces" ] } }, - "/v2/owners/{ownerAddress}/safes": { - "get": { - "description": "Retrieves all Safes owned by the specified address across all supported chains. Returns a map of chain IDs to arrays of Safe addresses.", - "operationId": "ownersGetAllSafesByOwnerV2", + "/v1/spaces/{spaceId}/chains/{chainId}/safes/{safeAddress}/policies/requests/{root}": { + "delete": { + "description": "Deletes the configurations stored behind a root, in any state. A root already requested on-chain stays there until invalidated.", + "operationId": "policiesDeleteConfigurationRequestV1", "parameters": [ { - "name": "ownerAddress", + "name": "spaceId", "required": true, "in": "path", - "description": "Owner address to search Safes for (0x prefixed hex string)", + "description": "Space UUID the Safe belongs to", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + }, + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the Safe is deployed", + "schema": { + "example": "11155111", + "type": "string" + } + }, + { + "name": "safeAddress", + "required": true, + "in": "path", + "description": "Safe contract address, must be registered to the Space", + "schema": { + "type": "string" + } + }, + { + "name": "root", + "required": true, + "in": "path", + "description": "The stored configuration root, a 32-byte hex", "schema": { "type": "string" } } ], "responses": { - "200": { - "description": "Map of chain IDs to arrays of Safe addresses owned by the address", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" - } - }, - "example": { - "1": [ - "0x1234567890123456789012345678901234567890" - ], - "5": [ - "0xabcdefabcdefabcdefabcdefabcdefabcdefabcd" - ] - } - } - } - } + "204": { + "description": "Configuration request deleted" + }, + "400": { + "description": "Invalid space identifier" + }, + "401": { + "description": "Authentication required" + }, + "403": { + "description": "Access forbidden - user is not a member of this space, or the Safe is not in it" + }, + "404": { + "description": "No configuration request is stored for this root" + }, + "422": { + "description": "Invalid chain ID, Safe address or root" } }, - "summary": "Get all Safes by owner", + "summary": "Delete a stored configuration request", "tags": [ - "owners" + "spaces" ] } }, - "/v3/owners/{ownerAddress}/safes": { + "/v1/spaces/{spaceId}/policies/active": { "get": { - "description": "Retrieves all Safes owned by the specified address across all supported chains. Returns a map of chain IDs to arrays of Safe addresses.", - "operationId": "ownersGetAllSafesByOwnerV3", + "description": "Returns the policies of every Safe in the Space. A Safe whose enabled modules and guards could not be read is omitted from the spending-limit and guard-enforced policies; a Safe whose delegates could not be read is omitted from the proposer policies.", + "operationId": "spacePoliciesGetActivePoliciesV1", "parameters": [ { - "name": "ownerAddress", + "name": "spaceId", "required": true, "in": "path", - "description": "Owner address to search Safes for (0x prefixed hex string)", + "description": "Space UUID", + "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", + "type": "string" + } + }, + { + "name": "types", + "required": true, + "in": "query", + "description": "The policy types to report, comma-separated.", "schema": { + "type": "array", + "items": { + "type": "string" + }, + "example": "spending-limit,proposer" + } + }, + { + "name": "safes", + "required": false, + "in": "query", + "description": "Narrow the read to a subset of the Space's Safes, comma-separated as `{chainId}:{safeAddress}`", + "schema": { + "example": "11155111:0x0000000000000000000000000000000000000000", "type": "string" } } ], "responses": { "200": { - "description": "Map of chain IDs to arrays of Safe addresses owned by the address", + "description": "", "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" - } - }, - "example": { - "1": [ - "0x1234567890123456789012345678901234567890" - ], - "5": [ - "0xabcdefabcdefabcdefabcdefabcdefabcdefabcd" - ] + "type": "array", + "items": { + "$ref": "#/components/schemas/ActivePolicyDto" } } } } - } - }, - "summary": "Get all Safes by owner", + }, + "400": { + "description": "Invalid space identifier" + }, + "403": { + "description": "Access forbidden - authentication missing or invalid, or user is not a member of this space" + }, + "422": { + "description": "Invalid CAIP-10 address, a Safe outside this space, or a missing or unknown policy type" + }, + "503": { + "description": "The policy api is unavailable" + } + }, + "summary": "Get the active policies on Safes in a Space", "tags": [ - "owners" + "spaces" ] } }, - "/v1/chains/{chainId}/relay": { - "post": { - "description": "Relays a Safe transaction or Safe creation transaction using the relay service, which pays for gas fees. Supports execTransaction (Safe tx) and createProxyWithNonce (Safe creation) calldata. On relay-fee chains, safeTxHash is required and must match the hash derived on-chain from the submitted calldata. On chains where pre-relay Tenderly simulation is enabled, an execTransaction is simulated before being submitted: a confirmed revert returns SIMULATION_FAILED, and an unreachable simulator returns INDETERMINATE_SIMULATION (retry with acceptUnverifiedSimulation=true to proceed anyway when the simulator is unreachable).", - "operationId": "relayRelayV1", + "/v1/spaces/{spaceId}/policies/pending": { + "get": { + "description": "Returns the pending policy changes of every Safe in the Space. Queued calls are detected only when made directly or one level inside a MultiSend batch, and only against known AllowanceModule and SafePolicyGuard deployments - a change made through a nested MultiSend, a custom batching contract, or a Safe module bypassing the owner queue is not detected.", + "operationId": "spacePoliciesGetPendingPoliciesV1", "parameters": [ { - "name": "chainId", + "name": "spaceId", "required": true, "in": "path", - "description": "Chain ID where the Safe transaction will be executed", + "description": "Space UUID", "schema": { - "example": "1", + "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } - } - ], - "requestBody": { - "required": true, - "description": "Transaction data to relay. safeTxHash is required on relay-fee chains and must correspond to the to + data fields. Set acceptUnverifiedSimulation=true to retry a relay skipping the simulation which previously returned INDETERMINATE_SIMULATION.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RelayDto" - } + }, + { + "name": "types", + "required": true, + "in": "query", + "description": "The policy types to report, comma-separated. `spending-limit` returns queued AllowanceModule changes. A guard type (`allow`, `deny`, `cosigner`, `erc20-transfer`, `multisend`, `native-transfer`) returns the delayed `SafePolicyGuard` configurations that may set a policy of that type. `proposer` and `recovery` return none.", + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "example": "spending-limit" + } + }, + { + "name": "safes", + "required": false, + "in": "query", + "description": "Narrow the read to a subset of the Space's Safes, comma-separated as `{chainId}:{safeAddress}`", + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "example": "11155111:0x0000000000000000000000000000000000000000" + } + }, + { + "name": "include_guard_installation", + "required": false, + "in": "query", + "description": "Also report the queued `setGuard` and `setModuleGuard` calls that install, replace or remove a `SafePolicyGuard` on each Safe, as `guard-installation` items.", + "schema": { + "default": false, + "example": true, + "type": "boolean" } } - }, + ], "responses": { "200": { - "description": "Transaction relayed successfully", + "description": "", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Relay" + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/PendingPolicyDto" + }, + { + "$ref": "#/components/schemas/PendingGuardInstallationDto" + }, + { + "$ref": "#/components/schemas/PendingImmediateGuardPoliciesDto" + }, + { + "$ref": "#/components/schemas/PendingDelayedGuardPoliciesDto" + } + ], + "discriminator": { + "propertyName": "kind", + "mapping": { + "queued-transaction": "#/components/schemas/PendingPolicyDto", + "guard-installation": "#/components/schemas/PendingGuardInstallationDto", + "immediate-guard-policies": "#/components/schemas/PendingImmediateGuardPoliciesDto", + "delayed-guard-policies": "#/components/schemas/PendingDelayedGuardPoliciesDto" + } + } + } } } } }, "400": { - "description": "Request body failed schema validation" + "description": "Invalid space identifier" }, "403": { - "description": "Relay denied: safeTxHash missing, fee service rejected, or unofficial proxy factory" + "description": "Access forbidden - authentication missing or invalid, or user is not a member of this space" }, "422": { - "description": "Relay rejected. The consumers MUST branch on the `code` field; `message` is informational. Possible cases: safeTxHash does not match the transaction data, unrecognised transaction type, SIMULATION_FAILED (Tenderly confirmed revert), or INDETERMINATE_SIMULATION (simulator unreachable; retry with `acceptUnverifiedSimulation=true` to proceed anyway).", - "schema": { - "examples": { - "simulationFailed": { - "summary": "SIMULATION_FAILED", - "value": { - "code": "SIMULATION_FAILED", - "message": "Relay denied: transaction simulation failed: Reverted with reason string: 'GS013'", - "statusCode": 422 - } - }, - "indeterminateSimulation": { - "summary": "INDETERMINATE_SIMULATION", - "value": { - "code": "INDETERMINATE_SIMULATION", - "message": "Relay simulation could not be completed.", - "statusCode": 422 - } - }, - "safeTxHashMismatch": { - "summary": "safeTxHash mismatch (no `code`)", - "value": { - "message": "Safe transaction hash mismatch: provided hash 0x... does not match the transaction data", - "statusCode": 422 - } - } - } - }, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RelayErrorResponse" - } - } - } + "description": "Invalid CAIP-10 address, a Safe outside this space, a missing or unknown policy type, or an `include_guard_installation` value other than `true` or `false`" }, - "429": { - "description": "Relay limit reached for this Safe" + "503": { + "description": "The policy api is unavailable" } }, - "summary": "Relay transaction", + "summary": "Get the pending policy changes on Safes in a Space", "tags": [ - "relay" + "spaces" ] } }, - "/v1/chains/{chainId}/relay/status/{taskId}": { + "/v1/surveys/{slug}": { "get": { - "description": "Retrieves the status of a relay task from the relay provider. This is a proxy endpoint to securely query task status without exposing the API key.", - "operationId": "relayGetTaskStatusV1", + "description": "Returns the active survey for the slug. It needs no space, so a Workspace that does not exist yet can show it.", + "operationId": "surveysGetActiveSurveyV1", "parameters": [ { - "name": "chainId", - "required": true, - "in": "path", - "description": "Chain ID associated with the relay task", - "schema": { - "example": "11155111", - "type": "string" - } - }, - { - "name": "taskId", + "name": "slug", "required": true, "in": "path", - "description": "Task ID returned from the relay transaction", "schema": { + "example": "onboarding", "type": "string" } } ], "responses": { "200": { - "description": "Task status retrieved successfully", + "description": "", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/RelayTaskStatus" + "$ref": "#/components/schemas/SurveyDto" } } } }, + "401": { + "description": "Not authenticated" + }, "404": { - "description": "Task not found" + "description": "No active survey for this slug" } }, - "summary": "Get relay task status", + "summary": "Get the active survey", "tags": [ - "relay" + "surveys" ] } }, - "/v1/chains/{chainId}/relay/{safeAddress}": { + "/v1/spaces/{spaceId}/surveys/{slug}/state": { "get": { - "description": "Retrieves the number of remaining relay transactions available for a specific Safe on the given chain. On relay-fee chains, safeTxHash is forwarded to the fee service to determine per-transaction eligibility (returns remaining=1 when eligible, 0 when not). On daily-limit and no-fee-campaign chains, a count-based quota is returned.", - "operationId": "relayGetRelaysRemainingV1", + "description": "Returns the active survey definition and this space's response (if any) in a single round trip. Only active admins of the space can read survey state.", + "operationId": "surveysGetStateV1", "parameters": [ { - "name": "chainId", + "name": "spaceId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", + "description": "Space UUID to get survey state for", "schema": { - "example": "1", + "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } }, { - "name": "safeAddress", + "name": "slug", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", - "schema": { - "type": "string" - } - }, - { - "name": "safeTxHash", - "required": false, - "in": "query", - "description": "Safe transaction hash (0x prefixed hex string). Required on relay-fee chains to check per-transaction eligibility with the fee service. Optional on daily-limit and no-fee-campaign chains.", "schema": { + "example": "onboarding", "type": "string" } } ], "responses": { "200": { - "description": "Remaining relay quota retrieved successfully", + "description": "", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/RelaysRemaining" + "$ref": "#/components/schemas/SurveyStateDto" } } } + }, + "400": { + "description": "Invalid space identifier" + }, + "401": { + "description": "Not authenticated" + }, + "403": { + "description": "User is not an active admin of this space" + }, + "404": { + "description": "No active survey for this slug" } }, - "summary": "Get remaining relays", + "summary": "Get survey state for a space", "tags": [ - "relay" + "surveys" ] } }, - "/v1/chains/{chainId}/safe-apps": { - "get": { - "description": "Retrieves a list of Safe Apps available for a specific chain, with optional filtering by client URL or app URL.", - "operationId": "safeAppsGetSafeAppsV1", + "/v1/spaces/{spaceId}/surveys/{slug}/responses": { + "post": { + "description": "Submits or updates the space's response to the active survey for the given slug. Only active admins of the space can submit. Idempotent: repeat submissions overwrite the previous response.", + "operationId": "surveysSubmitResponseV1", "parameters": [ { - "name": "chainId", + "name": "spaceId", "required": true, "in": "path", - "description": "Chain ID to get Safe Apps for", - "schema": { - "example": "1", - "type": "string" - } - }, - { - "name": "clientUrl", - "required": false, - "in": "query", - "description": "Filter by client URL to get apps compatible with specific client", + "description": "Space UUID to submit a survey response for", "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } }, { - "name": "url", - "required": false, - "in": "query", - "description": "Filter by specific Safe App URL", + "name": "slug", + "required": true, + "in": "path", "schema": { + "example": "onboarding", "type": "string" } } ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SubmitSurveyResponseDto" + } + } + } + }, "responses": { - "200": { - "description": "List of Safe Apps available for the specified chain", + "201": { + "description": "", "content": { "application/json": { "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SafeApp" - } + "$ref": "#/components/schemas/SurveyResponseResultDto" } } } + }, + "400": { + "description": "Empty selections or unknown option keys" + }, + "401": { + "description": "Not authenticated" + }, + "403": { + "description": "User is not an active admin of this space" + }, + "404": { + "description": "No active survey for this slug" } }, - "summary": "Get Safe Apps", + "summary": "Submit a survey response for a space", "tags": [ - "safe-apps" + "surveys" ] } }, - "/v1/chains/{chainId}/safes/{safeAddress}": { + "/v1/spaces/entitlements": { "get": { - "description": "Retrieves detailed information about a Safe including owners, threshold, modules, and current state.", - "operationId": "safesGetSafeV1", - "parameters": [ - { - "name": "chainId", - "required": true, - "in": "path", - "description": "Chain ID where the Safe is deployed", - "schema": { - "example": "1", - "type": "string" + "description": "The entitlements of every workspace the user is an active member of, keyed by workspace UUID. Each value is what the per-workspace endpoint returns.", + "operationId": "entitlementsGetAllEntitlementsV1", + "parameters": [], + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": { + "$ref": "#/components/schemas/EntitlementsResponse" + } + } + } } }, + "401": { + "description": "Authentication required" + }, + "403": { + "description": "Access forbidden - missing or invalid authentication" + } + }, + "summary": "Get entitlements of all spaces", + "tags": [ + "entitlements" + ] + } + }, + "/v1/spaces/{spaceId}/entitlements": { + "get": { + "description": "The single source of truth for what a workspace can do: the active plan and per-feature entitlements, with quotas and usage for metered ones. Free-tier workspaces get the same contract shape.", + "operationId": "entitlementsGetEntitlementsV1", + "parameters": [ { - "name": "safeAddress", + "name": "spaceId", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", + "description": "Space UUID", "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } } ], "responses": { "200": { - "description": "Safe information retrieved successfully", + "description": "", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SafeState" + "$ref": "#/components/schemas/EntitlementsResponse" } } } }, + "400": { + "description": "Invalid space identifier" + }, + "401": { + "description": "Authentication required" + }, + "403": { + "description": "Access forbidden - user is not a member of this space" + }, "404": { - "description": "Safe not found on the specified chain" + "description": "Space not found" } }, - "summary": "Get Safe information", + "summary": "Get space entitlements", "tags": [ - "safes" + "entitlements" ] } }, - "/v1/chains/{chainId}/safes/{safeAddress}/nonces": { - "get": { - "description": "Retrieves the current nonces for a Safe, including the transaction nonce and any queued nonces.", - "operationId": "safesGetNoncesV1", + "/v1/spaces/{spaceId}/chains/{chainId}/relay": { + "post": { + "description": "Relays a Safe transaction against the workspace's sponsored-transaction allowance, which its plan grants and this spends one unit of per call — a batch included. The chain must list SUBSCRIPTION among its gas payment options; no other option applies here. A call acting on an existing Safe is admitted only for a Safe the workspace holds; a Safe creation or a passkey signer deployment, having no Safe yet, is admitted as it is there.", + "operationId": "spaceRelayRelayV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", + "description": "Chain ID where the Safe transaction will be executed", "schema": { "example": "1", "type": "string" } }, { - "name": "safeAddress", + "name": "spaceId", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", + "description": "Space UUID", "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } } ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SpaceRelayDto" + } + } + } + }, "responses": { - "200": { - "description": "Safe nonces retrieved successfully", + "201": { + "description": "Transaction relayed", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SafeNonces" + "$ref": "#/components/schemas/Relay" } } } }, + "400": { + "description": "Malformed workspace identifier" + }, + "401": { + "description": "Authentication required" + }, + "402": { + "description": "The workspace's sponsored-transaction allowance is spent. The body carries `quota`, `used` and `resetsAt` so a client can offer to pay for the transaction itself." + }, + "403": { + "description": "Not a member of the workspace, or the transaction was denied" + }, "404": { - "description": "Safe not found on the specified chain" + "description": "Workspace not found" + }, + "409": { + "description": "SUBSCRIPTION cannot pay for this request: the chain does not list it or has no relayer, the Safe is not one the workspace holds, or the transaction refunds gas (`gasPrice` > 0).", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/GasPaymentOptionUnavailableResponse" + } + } + } + }, + "422": { + "description": "Request failed schema validation, or the transaction was simulated and would revert (SIMULATION_FAILED) or could not be simulated (INDETERMINATE_SIMULATION)" } }, - "summary": "Get Safe nonces", + "summary": "Relay a transaction at a workspace's expense", "tags": [ - "safes" + "relay" ] } }, - "/v1/safes": { - "get": { - "description": "Retrieves an overview of multiple Safes including their balances, transaction counts, and other summary information. Supports cross-chain queries using CAIP-10 address format.", - "operationId": "safesGetSafeOverviewV1", + "/v1/spaces/{spaceId}/chains/{chainId}/safes/{safeAddress}/safenet/checks": { + "post": { + "description": "Queues a Safenet check of a pending Safe transaction that an owner has signed. Safe Labs pays the fee and counts the check against the workspace in the path. The caller must be an active member of that workspace, the workspace must hold the Safe and its plan must grant policies (Business and Enterprise), and the chain must list SAFENET_CHECKS.", + "operationId": "safenetChecksRequestCheckV1", "parameters": [ { - "name": "currency", + "name": "chainId", "required": true, - "in": "query", - "description": "Fiat currency code for balance conversion (e.g., USD, EUR)", + "in": "path", + "description": "Chain ID where the Safe is deployed", "schema": { - "example": "USD", + "example": "1", "type": "string" } }, { - "name": "safes", + "name": "safeAddress", "required": true, - "in": "query", - "description": "Comma-separated list of Safe addresses in CAIP-10 format (chainId:address)", + "in": "path", + "description": "Safe contract address (0x prefixed hex string)", "schema": { - "example": "1:0x1234567890123456789012345678901234567890,5:0xabcdefabcdefabcdefabcdefabcdefabcdefabcd", "type": "string" } }, { - "name": "trusted", - "required": false, - "in": "query", - "description": "If true, only includes trusted tokens in balance calculations", - "schema": { - "example": false, - "type": "boolean" - } - }, - { - "name": "exclude_spam", - "required": false, - "in": "query", - "description": "If true, excludes spam tokens from balance calculations", - "schema": { - "example": true, - "type": "boolean" - } - }, - { - "name": "wallet_address", - "required": false, - "in": "query", - "description": "Optional wallet address to filter Safes where this address is an owner", + "name": "spaceId", + "required": true, + "in": "path", + "description": "Space UUID", "schema": { + "example": "123e4567-e89b-12d3-a456-426614174000", "type": "string" } } ], - "responses": { - "200": { - "description": "Array of Safe overviews with balances and metadata", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SafeOverview" - } - } + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateSafenetCheckDto" } } } }, - "summary": "Get Safe overview", + "responses": { + "202": { + "description": "Queued, or already queued" + }, + "400": { + "description": "Malformed workspace identifier" + }, + "401": { + "description": "Authentication required" + }, + "402": { + "description": "The workspace plan does not grant policies, which Safenet checks share. The body carries `{ code: \"FEATURE_NOT_GRANTED\", feature }`" + }, + "403": { + "description": "Not a member of the workspace, or the workspace does not hold the Safe" + }, + "404": { + "description": "Workspace not found, or no such transaction for this Safe" + }, + "422": { + "description": "The Safe is older than 1.3.0, or the transaction is executed or stale, unsigned by an owner, or of another Safe" + }, + "429": { + "description": "The workspace has used its daily limit of sponsored Safenet checks" + }, + "501": { + "description": "Safenet checks are not available on this chain" + } + }, + "summary": "Request a Safenet check at a workspace expense", "tags": [ - "safes" + "safenet" ] } }, - "/v2/safes": { + "/v1/chains/{chainId}/owners/{ownerAddress}/safes": { "get": { - "description": "Retrieves an overview of multiple Safes. Supports cross-chain queries using chainId:address format.", - "operationId": "safesGetSafeOverviewV2", + "description": "Retrieves a list of Safe addresses that are owned by the specified address on a specific chain.", + "operationId": "ownersGetSafesByOwnerV1", "parameters": [ { - "name": "currency", + "name": "chainId", "required": true, - "in": "query", - "description": "Fiat currency code for balance conversion (e.g., USD, EUR)", + "in": "path", + "description": "Chain ID to search for Safes", "schema": { - "example": "USD", + "example": "1", "type": "string" } }, { - "name": "safes", + "name": "ownerAddress", "required": true, - "in": "query", - "description": "Comma-separated list of Safe addresses in chainId:address format", - "schema": { - "example": "1:0x1234567890123456789012345678901234567890,5:0xabcdefabcdefabcdefabcdefabcdefabcdefabcd", - "type": "string" - } - }, - { - "name": "trusted", - "required": false, - "in": "query", - "description": "If true, only includes trusted tokens in balance calculations.", - "schema": { - "example": false, - "type": "boolean" - } - }, - { - "name": "wallet_address", - "required": false, - "in": "query", - "description": "Optional wallet address to filter Safes where this address is an owner", + "in": "path", + "description": "Owner address to search Safes for (0x prefixed hex string)", "schema": { "type": "string" } @@ -4388,54 +5392,32 @@ ], "responses": { "200": { - "description": "Array of Safe overviews with balances and metadata", + "description": "List of Safes owned by the specified address", "content": { "application/json": { "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SafeOverview" - } + "$ref": "#/components/schemas/SafeList" } } } } }, - "summary": "Get Safe overview (v2)", + "summary": "Get Safes by owner", "tags": [ - "safes" + "owners" ] } }, - "/v1/chains/{chainId}/security/{safeAddress}/recipient/{recipientAddress}": { + "/v2/owners/{ownerAddress}/safes": { "get": { - "description": "Performs real-time security analysis of a recipient address for a specific Safe. Returns analysis results grouped by status group, sorted by severity (CRITICAL first).", - "operationId": "safeShieldAnalyzeRecipientV1", + "description": "Retrieves all Safes owned by the specified address across all supported chains. Returns a map of chain IDs to arrays of Safe addresses.", + "operationId": "ownersGetAllSafesByOwnerV2", "parameters": [ { - "name": "chainId", + "name": "ownerAddress", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", - "schema": { - "example": "1", - "type": "string" - } - }, - { - "name": "safeAddress", - "required": true, - "in": "path", - "description": "Safe contract address", - "schema": { - "type": "string" - } - }, - { - "name": "recipientAddress", - "required": true, - "in": "path", - "description": "Recipient address to analyze", + "description": "Owner address to search Safes for (0x prefixed hex string)", "schema": { "type": "string" } @@ -4443,207 +5425,259 @@ ], "responses": { "200": { - "description": "Recipient interaction analysis results", + "description": "Map of chain IDs to arrays of Safe addresses owned by the address", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SingleRecipientAnalysisDto" + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } + }, + "example": { + "1": [ + "0x1234567890123456789012345678901234567890" + ], + "5": [ + "0xabcdefabcdefabcdefabcdefabcdefabcdefabcd" + ] + } } } } } }, - "summary": "Analyze recipient address", + "summary": "Get all Safes by owner", "tags": [ - "safe-shield" + "owners" ] } }, - "/v1/chains/{chainId}/security/{safeAddress}/counterparty-analysis": { - "post": { - "description": "Performs combined contract and recipient analysis for a Safe transaction. Returns both analyses grouped by status group for each counterparty.", - "operationId": "safeShieldAnalyzeCounterpartyV1", + "/v3/owners/{ownerAddress}/safes": { + "get": { + "description": "Retrieves all Safes owned by the specified address across all supported chains. Returns a map of chain IDs to arrays of Safe addresses.", + "operationId": "ownersGetAllSafesByOwnerV3", "parameters": [ { - "name": "chainId", - "required": true, - "in": "path", - "description": "Chain ID where the Safe is deployed", - "schema": { - "example": "1", - "type": "string" - } - }, - { - "name": "safeAddress", + "name": "ownerAddress", "required": true, "in": "path", - "description": "Safe contract address", + "description": "Owner address to search Safes for (0x prefixed hex string)", "schema": { "type": "string" } } ], - "requestBody": { - "required": true, - "description": "Transaction data used to analyze all counterparties involved.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CounterpartyAnalysisRequestDto" - } - } - } - }, "responses": { "200": { - "description": "Combined counterparty analysis including recipients and contracts grouped by status group and mapped to an address.", + "description": "Map of chain IDs to arrays of Safe addresses owned by the address", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/CounterpartyAnalysisDto" + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } + }, + "example": { + "1": [ + "0x1234567890123456789012345678901234567890" + ], + "5": [ + "0xabcdefabcdefabcdefabcdefabcdefabcdefabcd" + ] + } } } } } }, - "summary": "Analyze transaction counterparties", + "summary": "Get all Safes by owner", "tags": [ - "safe-shield" + "owners" ] } }, - "/v1/chains/{chainId}/security/{safeAddress}/threat-analysis": { + "/v1/chains/{chainId}/relay": { "post": { - "description": "Performs real-time threat analysis for a Safe transaction.", - "operationId": "safeShieldAnalyzeThreatV1", + "description": "Relays a Safe transaction or Safe creation transaction using the relay service, which pays for gas fees. Supports execTransaction (Safe tx) and createProxyWithNonce (Safe creation) calldata. On relay-fee chains, safeTxHash is required and must match the hash derived on-chain from the submitted calldata. On chains where pre-relay Tenderly simulation is enabled, an execTransaction is simulated before being submitted: a confirmed revert returns SIMULATION_FAILED, and an unreachable simulator returns INDETERMINATE_SIMULATION (retry with acceptUnverifiedSimulation=true to proceed anyway when the simulator is unreachable).", + "operationId": "relayRelayV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", - "schema": { - "type": "string" - } - }, - { - "name": "safeAddress", - "required": true, - "in": "path", - "description": "Safe contract address", + "description": "Chain ID where the Safe transaction will be executed", "schema": { + "example": "1", "type": "string" } } ], "requestBody": { "required": true, - "description": "EIP-712 typed data and wallet information for threat analysis.", + "description": "Transaction data to relay. safeTxHash is required on relay-fee chains and must correspond to the to + data fields. Set acceptUnverifiedSimulation=true to retry a relay skipping the simulation which previously returned INDETERMINATE_SIMULATION.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ThreatAnalysisRequestDto" + "$ref": "#/components/schemas/RelayDto" } } } }, "responses": { "200": { - "description": "Threat analysis results including threat findings and balance changes.", + "description": "Transaction relayed successfully", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ThreatAnalysisResponseDto" + "$ref": "#/components/schemas/Relay" + } + } + } + }, + "400": { + "description": "Request body failed schema validation" + }, + "403": { + "description": "Relay denied: safeTxHash missing, fee service rejected, or unofficial proxy factory" + }, + "409": { + "description": "A transaction that refunds gas (`gasPrice` > 0) needs PAY_FROM_SAFE, which the chain does not offer.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/GasPaymentOptionUnavailableResponse" + } + } + } + }, + "422": { + "description": "Relay rejected. The consumers MUST branch on the `code` field; `message` is informational. Possible cases: safeTxHash does not match the transaction data, unrecognised transaction type, SIMULATION_FAILED (Tenderly confirmed revert), or INDETERMINATE_SIMULATION (simulator unreachable; retry with `acceptUnverifiedSimulation=true` to proceed anyway).", + "schema": { + "examples": { + "simulationFailed": { + "summary": "SIMULATION_FAILED", + "value": { + "code": "SIMULATION_FAILED", + "message": "Relay denied: transaction simulation failed: Reverted with reason string: 'GS013'", + "statusCode": 422 + } + }, + "indeterminateSimulation": { + "summary": "INDETERMINATE_SIMULATION", + "value": { + "code": "INDETERMINATE_SIMULATION", + "message": "Relay simulation could not be completed.", + "statusCode": 422 + } + }, + "safeTxHashMismatch": { + "summary": "safeTxHash mismatch (no `code`)", + "value": { + "message": "Safe transaction hash mismatch: provided hash 0x... does not match the transaction data", + "statusCode": 422 + } + } + } + }, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RelayErrorResponse" } } } + }, + "429": { + "description": "Relay limit reached for this Safe" } }, - "summary": "Analyze transaction threat", + "summary": "Relay transaction", "tags": [ - "safe-shield" + "relay" ] } }, - "/v1/chains/{chainId}/security/{safeAddress}/report-false-result": { - "post": { - "description": "Reports a FALSE_POSITIVE or FALSE_NEGATIVE Blockaid transaction scan result for review. Use the request_id from the original scan response to identify the transaction.", - "operationId": "safeShieldReportFalseResultV1", + "/v1/chains/{chainId}/relay/status/{taskId}": { + "get": { + "description": "Retrieves the status of a relay task from the relay provider. This is a proxy endpoint to securely query task status without exposing the API key.", + "operationId": "relayGetTaskStatusV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", + "description": "Chain ID associated with the relay task", "schema": { - "example": "1", + "example": "11155111", "type": "string" } }, { - "name": "safeAddress", + "name": "taskId", "required": true, "in": "path", - "description": "Safe contract address", + "description": "Task ID returned from the relay transaction", "schema": { "type": "string" } } ], - "requestBody": { - "required": true, - "description": "Report details including event type, request_id from scan response, and details.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ReportFalseResultRequestDto" - } - } - } - }, "responses": { "200": { - "description": "Report submitted successfully.", + "description": "Task status retrieved successfully", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ReportFalseResultResponseDto" + "$ref": "#/components/schemas/RelayTaskStatus" } } } + }, + "404": { + "description": "Task not found" } }, - "summary": "Report false Blockaid scan result", + "summary": "Get relay task status", "tags": [ - "safe-shield" + "relay" ] } }, - "/v1/targeted-messaging/outreaches/{outreachId}/chains/{chainId}/safes/{safeAddress}": { + "/v1/chains/{chainId}/relay/{safeAddress}": { "get": { - "operationId": "targetedMessagingGetTargetedSafeV1", + "description": "Retrieves the free relays left for a specific Safe on the given chain: the no-fee campaign quota where the chain lists NO_FEE_CAMPAIGN, otherwise the daily limit where it lists FREE_DAILY_LIMIT.", + "operationId": "relayGetRelaysRemainingV1", "parameters": [ { - "name": "outreachId", + "name": "chainId", "required": true, "in": "path", + "description": "Chain ID where the Safe is deployed", "schema": { - "type": "number" + "example": "1", + "type": "string" } }, { - "name": "chainId", + "name": "safeAddress", "required": true, "in": "path", + "description": "Safe contract address (0x prefixed hex string)", "schema": { "type": "string" } }, { - "name": "safeAddress", - "required": true, - "in": "path", + "name": "safeTxHash", + "required": false, + "in": "query", + "description": "Safe transaction hash (0x prefixed hex string). Ignored; kept so existing clients do not break.", "schema": { "type": "string" } @@ -4651,56 +5685,54 @@ ], "responses": { "200": { - "description": "", + "description": "Remaining relay quota retrieved successfully", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/TargetedSafe" + "$ref": "#/components/schemas/RelaysRemaining" } } } }, - "404": { - "description": "Safe not targeted." + "403": { + "description": "The chain has no relayer or lists no free option, such as a chain that only lists PAY_FROM_SAFE" } }, + "summary": "Get remaining relays", "tags": [ - "targeted-messaging" + "relay" ] } }, - "/v1/targeted-messaging/outreaches/{outreachId}/chains/{chainId}/safes/{safeAddress}/signers/{signerAddress}/submissions": { + "/v1/chains/{chainId}/safe-apps": { "get": { - "operationId": "targetedMessagingGetSubmissionV1", + "description": "Retrieves a list of Safe Apps available for a specific chain, with optional filtering by client URL or app URL.", + "operationId": "safeAppsGetSafeAppsV1", "parameters": [ { - "name": "outreachId", - "required": true, - "in": "path", - "schema": { - "type": "number" - } - }, - { - "name": "chainId", + "name": "chainId", "required": true, "in": "path", + "description": "Chain ID to get Safe Apps for", "schema": { + "example": "1", "type": "string" } }, { - "name": "safeAddress", - "required": true, - "in": "path", + "name": "clientUrl", + "required": false, + "in": "query", + "description": "Filter by client URL to get apps compatible with specific client", "schema": { "type": "string" } }, { - "name": "signerAddress", - "required": true, - "in": "path", + "name": "url", + "required": false, + "in": "query", + "description": "Filter by specific Safe App URL", "schema": { "type": "string" } @@ -4708,36 +5740,37 @@ ], "responses": { "200": { - "description": "", + "description": "List of Safe Apps available for the specified chain", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Submission" + "type": "array", + "items": { + "$ref": "#/components/schemas/SafeApp" + } } } } } }, + "summary": "Get Safe Apps", "tags": [ - "targeted-messaging" + "safe-apps" ] - }, - "post": { - "operationId": "targetedMessagingCreateSubmissionV1", + } + }, + "/v1/chains/{chainId}/safes/{safeAddress}": { + "get": { + "description": "Retrieves detailed information about a Safe including owners, threshold, modules, and current state.", + "operationId": "safesGetSafeV1", "parameters": [ - { - "name": "outreachId", - "required": true, - "in": "path", - "schema": { - "type": "number" - } - }, { "name": "chainId", "required": true, "in": "path", + "description": "Chain ID where the Safe is deployed", "schema": { + "example": "1", "type": "string" } }, @@ -4745,176 +5778,195 @@ "name": "safeAddress", "required": true, "in": "path", - "schema": { - "type": "string" - } - }, - { - "name": "signerAddress", - "required": true, - "in": "path", + "description": "Safe contract address (0x prefixed hex string)", "schema": { "type": "string" } } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateSubmissionDto" - } - } - } - }, "responses": { - "201": { - "description": "", + "200": { + "description": "Safe information retrieved successfully", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Submission" + "$ref": "#/components/schemas/SafeState" } } } + }, + "404": { + "description": "Safe not found on the specified chain" } }, + "summary": "Get Safe information", "tags": [ - "targeted-messaging" + "safes" ] } }, - "/v1/chains/{chainId}/transactions/{id}": { + "/v1/chains/{chainId}/safes/{safeAddress}/nonces": { "get": { - "description": "Retrieves detailed information about a specific transaction by its ID, including execution status, confirmations, and decoded transaction data.", - "operationId": "transactionsGetTransactionByIdV1", + "description": "Retrieves the current nonces for a Safe, including the transaction nonce and any queued nonces.", + "operationId": "safesGetNoncesV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the transaction exists", + "description": "Chain ID where the Safe is deployed", "schema": { "example": "1", "type": "string" } }, { - "name": "id", + "name": "safeAddress", "required": true, "in": "path", - "description": "Transaction ID (safe transaction hash or multisig transaction ID)", + "description": "Safe contract address (0x prefixed hex string)", "schema": { - "example": "multisig_0x1234567890123456789012345678901234567890_0x5678...", "type": "string" } } ], "responses": { "200": { - "description": "Transaction details retrieved successfully", + "description": "Safe nonces retrieved successfully", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/TransactionDetails" + "$ref": "#/components/schemas/SafeNonces" } } } }, "404": { - "description": "Transaction not found" + "description": "Safe not found on the specified chain" } }, - "summary": "Get transaction details", + "summary": "Get Safe nonces", "tags": [ - "transactions" + "safes" ] } }, - "/v1/chains/{chainId}/safes/{safeAddress}/multisig-transactions": { + "/v1/safes": { "get": { - "description": "Retrieves a paginated list of multisig transactions for a Safe with optional filtering by execution date, recipient, value, nonce, and execution status.", - "operationId": "transactionsGetMultisigTransactionsV1", + "description": "Retrieves an overview of multiple Safes including their balances, transaction counts, and other summary information. Supports cross-chain queries using CAIP-10 address format.", + "operationId": "safesGetSafeOverviewV1", "parameters": [ { - "name": "chainId", + "name": "currency", "required": true, - "in": "path", - "description": "Chain ID where the Safe is deployed", + "in": "query", + "description": "Fiat currency code for balance conversion (e.g., USD, EUR)", "schema": { - "example": "1", + "example": "USD", "type": "string" } }, { - "name": "safeAddress", + "name": "safes", "required": true, - "in": "path", - "description": "Safe contract address (0x prefixed hex string)", + "in": "query", + "description": "Comma-separated list of Safe addresses in CAIP-10 format (chainId:address)", "schema": { + "example": "1:0x1234567890123456789012345678901234567890,5:0xabcdefabcdefabcdefabcdefabcdefabcdefabcd", "type": "string" } }, { - "name": "execution_date__gte", + "name": "trusted", "required": false, "in": "query", - "description": "Filter by execution date greater than or equal to (ISO 8601 format)", + "description": "If true, only includes trusted tokens in balance calculations", "schema": { - "type": "string" + "example": false, + "type": "boolean" } }, { - "name": "execution_date__lte", + "name": "exclude_spam", "required": false, "in": "query", - "description": "Filter by execution date less than or equal to (ISO 8601 format)", + "description": "If true, excludes spam tokens from balance calculations", "schema": { - "type": "string" + "example": true, + "type": "boolean" } }, { - "name": "to", + "name": "wallet_address", "required": false, "in": "query", - "description": "Filter by recipient address (0x prefixed hex string)", + "description": "Optional wallet address to filter Safes where this address is an owner", "schema": { "type": "string" } - }, + } + ], + "responses": { + "200": { + "description": "Array of Safe overviews with balances and metadata", + "content": { + "application/json": { + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SafeOverview" + } + } + } + } + } + }, + "summary": "Get Safe overview", + "tags": [ + "safes" + ] + } + }, + "/v2/safes": { + "get": { + "description": "Retrieves an overview of multiple Safes. Supports cross-chain queries using chainId:address format.", + "operationId": "safesGetSafeOverviewV2", + "parameters": [ { - "name": "value", - "required": false, + "name": "currency", + "required": true, "in": "query", - "description": "Filter by transaction value in wei", + "description": "Fiat currency code for balance conversion (e.g., USD, EUR)", "schema": { + "example": "USD", "type": "string" } }, { - "name": "nonce", - "required": false, + "name": "safes", + "required": true, "in": "query", - "description": "Filter by transaction nonce", + "description": "Comma-separated list of Safe addresses in chainId:address format", "schema": { + "example": "1:0x1234567890123456789012345678901234567890,5:0xabcdefabcdefabcdefabcdefabcdefabcdefabcd", "type": "string" } }, { - "name": "executed", + "name": "trusted", "required": false, "in": "query", - "description": "Filter by execution status (true for executed, false for pending)", + "description": "If true, only includes trusted tokens in balance calculations.", "schema": { + "example": false, "type": "boolean" } }, { - "name": "cursor", + "name": "wallet_address", "required": false, "in": "query", - "description": "Pagination cursor for retrieving the next set of results", + "description": "Optional wallet address to filter Safes where this address is an owner", "schema": { "type": "string" } @@ -4922,79 +5974,84 @@ ], "responses": { "200": { - "description": "Paginated list of multisig transactions", + "description": "Array of Safe overviews with balances and metadata", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/MultisigTransactionPage" + "type": "array", + "items": { + "$ref": "#/components/schemas/SafeOverview" + } } } } } }, - "summary": "Get multisig transactions", + "summary": "Get Safe overview (v2)", "tags": [ - "transactions" + "safes" ] } }, - "/v1/chains/{chainId}/transactions/{safeTxHash}": { - "delete": { - "description": "Deletes a pending multisig transaction. Only the proposer or a Safe owner can delete a transaction.", - "operationId": "transactionsDeleteTransactionV1", + "/v1/chains/{chainId}/security/{safeAddress}/recipient/{recipientAddress}": { + "get": { + "description": "Performs real-time security analysis of a recipient address for a specific Safe. Returns analysis results grouped by status group, sorted by severity (CRITICAL first).", + "operationId": "safeShieldAnalyzeRecipientV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the transaction exists", + "description": "Chain ID where the Safe is deployed", "schema": { "example": "1", "type": "string" } }, { - "name": "safeTxHash", + "name": "safeAddress", "required": true, "in": "path", - "description": "Safe transaction hash (0x prefixed hex string)", + "description": "Safe contract address", + "schema": { + "type": "string" + } + }, + { + "name": "recipientAddress", + "required": true, + "in": "path", + "description": "Recipient address to analyze", "schema": { "type": "string" } } ], - "requestBody": { - "required": true, - "description": "Signature proving authorization to delete the transaction", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DeleteTransactionDto" + "responses": { + "200": { + "description": "Recipient interaction analysis results", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SingleRecipientAnalysisDto" + } } } - } - }, - "responses": { - "204": { - "description": "Transaction deleted successfully" - }, - "400": { - "description": "Invalid signature or unauthorized deletion attempt" }, - "404": { - "description": "Transaction not found" + "402": { + "description": "Disabled on Core. The body carries `{ code: \"SAFE_SHIELD_DISABLED_ON_CORE\", message }`." } }, - "summary": "Delete transaction", + "summary": "Analyze recipient address", "tags": [ - "transactions" + "safe-shield" ] } }, - "/v1/chains/{chainId}/safes/{safeAddress}/module-transactions": { - "get": { - "description": "Retrieves a paginated list of module transactions for a Safe. Module transactions are executed directly by enabled modules without requiring owner signatures.", - "operationId": "transactionsGetModuleTransactionsV1", + "/v1/chains/{chainId}/security/{safeAddress}/counterparty-analysis": { + "post": { + "description": "Performs combined contract and recipient analysis for a Safe transaction. Returns both analyses grouped by status group for each counterparty.", + "operationId": "safeShieldAnalyzeCounterpartyV1", "parameters": [ { "name": "chainId", @@ -5010,70 +6067,98 @@ "name": "safeAddress", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", + "description": "Safe contract address", "schema": { "type": "string" } - }, - { - "name": "to", - "required": false, - "in": "query", - "description": "Filter by recipient address (0x prefixed hex string)", - "schema": { - "type": "string" + } + ], + "requestBody": { + "required": true, + "description": "Transaction data used to analyze all counterparties involved.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CounterpartyAnalysisRequestDto" + } } - }, - { - "name": "module", - "required": false, - "in": "query", - "description": "Filter by module address that executed the transaction", - "schema": { - "type": "string" + } + }, + "responses": { + "200": { + "description": "Combined counterparty analysis including recipients and contracts grouped by status group and mapped to an address.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CounterpartyAnalysisDto" + } + } } - }, + } + }, + "summary": "Analyze transaction counterparties", + "tags": [ + "safe-shield" + ] + } + }, + "/v1/chains/{chainId}/security/{safeAddress}/threat-analysis": { + "post": { + "description": "Performs real-time threat analysis for a Safe transaction.", + "operationId": "safeShieldAnalyzeThreatV1", + "parameters": [ { - "name": "transaction_hash", - "required": false, - "in": "query", - "description": "Filter by specific transaction hash", + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the Safe is deployed", "schema": { "type": "string" } }, { - "name": "cursor", - "required": false, - "in": "query", - "description": "Pagination cursor for retrieving the next set of results", + "name": "safeAddress", + "required": true, + "in": "path", + "description": "Safe contract address", "schema": { "type": "string" } } ], + "requestBody": { + "required": true, + "description": "EIP-712 typed data and wallet information for threat analysis.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThreatAnalysisRequestDto" + } + } + } + }, "responses": { "200": { - "description": "Paginated list of module transactions", + "description": "Threat analysis results including threat findings and balance changes.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ModuleTransactionPage" + "$ref": "#/components/schemas/ThreatAnalysisResponseDto" } } } } }, - "summary": "Get module transactions", + "summary": "Analyze transaction threat", "tags": [ - "transactions" + "safe-shield" ] } }, - "/v1/chains/{chainId}/transactions/{safeTxHash}/confirmations": { + "/v1/chains/{chainId}/security/{safeAddress}/report-false-result": { "post": { - "description": "Adds a confirmation signature to a pending multisig transaction. Once enough confirmations are collected to meet the Safe threshold, the transaction can be executed.", - "operationId": "transactionsAddConfirmationV1", + "description": "Reports a FALSE_POSITIVE or FALSE_NEGATIVE Blockaid transaction scan result for review. Use the request_id from the original scan response to identify the transaction.", + "operationId": "safeShieldReportFalseResultV1", "parameters": [ { "name": "chainId", @@ -5086,10 +6171,10 @@ } }, { - "name": "safeTxHash", + "name": "safeAddress", "required": true, "in": "path", - "description": "Safe transaction hash (0x prefixed hex string)", + "description": "Safe contract address", "schema": { "type": "string" } @@ -5097,122 +6182,114 @@ ], "requestBody": { "required": true, - "description": "Confirmation signature from a Safe owner proving their approval of the transaction", + "description": "Report details including event type, request_id from scan response, and details.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/AddConfirmationDto" + "$ref": "#/components/schemas/ReportFalseResultRequestDto" } } } }, "responses": { "200": { - "description": "Transaction details with updated confirmation status", + "description": "Report submitted successfully.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Transaction" + "$ref": "#/components/schemas/ReportFalseResultResponseDto" } } } - }, - "400": { - "description": "Invalid signature or confirmation already exists for this owner" - }, - "404": { - "description": "Transaction not found" } }, - "summary": "Add transaction confirmation", + "summary": "Report false Blockaid scan result", "tags": [ - "transactions" + "safe-shield" ] } }, - "/v1/chains/{chainId}/safes/{safeAddress}/incoming-transfers": { + "/v1/targeted-messaging/outreaches/{outreachId}/chains/{chainId}/safes/{safeAddress}": { "get": { - "description": "Retrieves a paginated list of incoming transfers to a Safe, including ETH and token transfers with optional filtering by date, value, token, and trust status.", - "operationId": "transactionsGetIncomingTransfersV1", + "operationId": "targetedMessagingGetTargetedSafeV1", "parameters": [ { - "name": "chainId", + "name": "outreachId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", "schema": { - "example": "1", - "type": "string" + "type": "number" } }, { - "name": "safeAddress", + "name": "chainId", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", "schema": { "type": "string" } }, { - "name": "trusted", - "required": false, - "in": "query", - "description": "Filter by trust status (true for trusted tokens, false for untrusted)", - "schema": { - "type": "boolean" - } - }, - { - "name": "execution_date__gte", - "required": false, - "in": "query", - "description": "Filter by execution date greater than or equal to (ISO 8601 format)", + "name": "safeAddress", + "required": true, + "in": "path", "schema": { "type": "string" } - }, - { - "name": "execution_date__lte", - "required": false, - "in": "query", - "description": "Filter by execution date less than or equal to (ISO 8601 format)", - "schema": { - "type": "string" + } + ], + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/TargetedSafe" + } + } } }, + "404": { + "description": "Safe not targeted." + } + }, + "tags": [ + "targeted-messaging" + ] + } + }, + "/v1/targeted-messaging/outreaches/{outreachId}/chains/{chainId}/safes/{safeAddress}/signers/{signerAddress}/submissions": { + "get": { + "operationId": "targetedMessagingGetSubmissionV1", + "parameters": [ { - "name": "to", - "required": false, - "in": "query", - "description": "Filter by recipient address (0x prefixed hex string)", + "name": "outreachId", + "required": true, + "in": "path", "schema": { - "type": "string" + "type": "number" } }, { - "name": "value", - "required": false, - "in": "query", - "description": "Filter by transfer value in wei", + "name": "chainId", + "required": true, + "in": "path", "schema": { "type": "string" } }, { - "name": "token_address", - "required": false, - "in": "query", - "description": "Filter by token contract address (0x prefixed hex string for ERC-20 tokens)", + "name": "safeAddress", + "required": true, + "in": "path", "schema": { "type": "string" } }, { - "name": "cursor", - "required": false, - "in": "query", - "description": "Pagination cursor for retrieving the next set of results", + "name": "signerAddress", + "required": true, + "in": "path", "schema": { "type": "string" } @@ -5220,34 +6297,36 @@ ], "responses": { "200": { - "description": "Paginated list of incoming transfers", + "description": "", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/IncomingTransferPage" + "$ref": "#/components/schemas/Submission" } } } } }, - "summary": "Get incoming transfers", "tags": [ - "transactions" + "targeted-messaging" ] - } - }, - "/v1/chains/{chainId}/transactions/{safeAddress}/preview": { + }, "post": { - "description": "Simulates a transaction execution to preview its effects, including gas estimates, balance changes, and potential errors before actually proposing or executing it.", - "operationId": "transactionsPreviewTransactionV1", + "operationId": "targetedMessagingCreateSubmissionV1", "parameters": [ + { + "name": "outreachId", + "required": true, + "in": "path", + "schema": { + "type": "number" + } + }, { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", "schema": { - "example": "1", "type": "string" } }, @@ -5255,7 +6334,14 @@ "name": "safeAddress", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "signerAddress", + "required": true, + "in": "path", "schema": { "type": "string" } @@ -5263,104 +6349,82 @@ ], "requestBody": { "required": true, - "description": "Transaction data to preview including recipient, value, data, and operation type", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PreviewTransactionDto" + "$ref": "#/components/schemas/CreateSubmissionDto" } } } }, "responses": { - "200": { - "description": "Transaction preview with simulation results, gas estimates, and potential effects", + "201": { + "description": "", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/TransactionPreview" + "$ref": "#/components/schemas/Submission" } } } - }, - "400": { - "description": "Invalid transaction data or simulation failed" - }, - "404": { - "description": "Safe not found" } }, - "summary": "Preview transaction", "tags": [ - "transactions" + "targeted-messaging" ] } }, - "/v1/chains/{chainId}/safes/{safeAddress}/transactions/queued": { + "/v1/chains/{chainId}/transactions/{id}": { "get": { - "description": "Retrieves a paginated list of queued (pending) transactions for a Safe that are waiting for execution, ordered by nonce.", - "operationId": "transactionsGetTransactionQueueV1", + "description": "Retrieves detailed information about a specific transaction by its ID, including execution status, confirmations, and decoded transaction data.", + "operationId": "transactionsGetTransactionByIdV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", + "description": "Chain ID where the transaction exists", "schema": { "example": "1", "type": "string" } }, { - "name": "safeAddress", + "name": "id", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", - "schema": { - "type": "string" - } - }, - { - "name": "trusted", - "required": false, - "in": "query", - "description": "Filter by trust status (true for trusted transactions, false for untrusted)", - "schema": { - "type": "boolean" - } - }, - { - "name": "cursor", - "required": false, - "in": "query", - "description": "Pagination cursor for retrieving the next set of results", + "description": "Transaction ID (safe transaction hash or multisig transaction ID)", "schema": { + "example": "multisig_0x1234567890123456789012345678901234567890_0x5678...", "type": "string" } } ], "responses": { "200": { - "description": "Paginated list of queued transactions", + "description": "Transaction details retrieved successfully", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/QueuedItemPage" + "$ref": "#/components/schemas/TransactionDetails" } } } + }, + "404": { + "description": "Transaction not found" } }, - "summary": "Get transaction queue", + "summary": "Get transaction details", "tags": [ "transactions" ] } }, - "/v1/chains/{chainId}/safes/{safeAddress}/transactions/history": { + "/v1/chains/{chainId}/safes/{safeAddress}/multisig-transactions": { "get": { - "description": "Retrieves a paginated list of executed transactions for a Safe, including multisig transactions, module transactions, and incoming transfers, ordered by execution date.", - "operationId": "transactionsGetTransactionsHistoryV1", + "description": "Retrieves a paginated list of multisig transactions for a Safe with optional filtering by execution date, recipient, value, nonce, and execution status.", + "operationId": "transactionsGetMultisigTransactionsV1", "parameters": [ { "name": "chainId", @@ -5372,6 +6436,15 @@ "type": "string" } }, + { + "name": "cursor", + "required": false, + "in": "query", + "description": "Pagination cursor for retrieving the next set of results", + "schema": { + "type": "string" + } + }, { "name": "safeAddress", "required": true, @@ -5382,90 +6455,101 @@ } }, { - "name": "timezone_offset", + "name": "execution_date__gte", "required": false, "in": "query", - "deprecated": true, - "description": "Deprecated: Timezone offset in milliseconds for date formatting (use timezone parameter instead)", + "description": "Filter by execution date greater than or equal to (ISO 8601 format)", "schema": { "type": "string" } }, { - "name": "trusted", + "name": "execution_date__lte", "required": false, "in": "query", - "description": "Filter by trust status (default: true, set to false to include untrusted transactions)", + "description": "Filter by execution date less than or equal to (ISO 8601 format)", "schema": { - "type": "boolean" + "type": "string" } }, { - "name": "imitation", + "name": "to", "required": false, "in": "query", - "description": "Include imitation transactions in results (default: true, set to false to exclude)", + "description": "Filter by recipient address (0x prefixed hex string)", "schema": { - "type": "boolean" + "type": "string" } }, { - "name": "timezone", + "name": "value", "required": false, "in": "query", - "description": "IANA timezone identifier for date formatting (e.g., \"America/New_York\")", + "description": "Filter by transaction value in wei", "schema": { "type": "string" } }, { - "name": "cursor", + "name": "nonce", "required": false, "in": "query", - "description": "Pagination cursor for retrieving the next set of results", + "description": "Filter by transaction nonce", "schema": { "type": "string" } + }, + { + "name": "executed", + "required": false, + "in": "query", + "description": "Filter by execution status (true for executed, false for pending)", + "schema": { + "type": "boolean" + } } ], "responses": { "200": { - "description": "Paginated list of historical transactions", + "description": "Paginated list of multisig transactions", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/TransactionItemPage" + "$ref": "#/components/schemas/MultisigTransactionPage" } } } + }, + "422": { + "description": "Invalid cursor" } }, - "summary": "Get transaction history", + "summary": "Get multisig transactions", "tags": [ "transactions" ] } }, - "/v1/chains/{chainId}/transactions/{safeAddress}/propose": { - "post": { - "description": "Proposes a new multisig transaction for a Safe. The transaction will be pending until enough owners sign it to reach the required threshold.", - "operationId": "transactionsProposeTransactionV1", + "/v1/chains/{chainId}/transactions/{safeTxHash}": { + "delete": { + "description": "Deletes a pending multisig transaction. Only the proposer or a Safe owner can delete a transaction.", + "operationId": "transactionsDeleteTransactionV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", + "description": "Chain ID where the transaction exists", "schema": { "example": "1", "type": "string" } }, { - "name": "safeAddress", + "name": "safeTxHash", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", + "description": "Safe transaction hash (0x prefixed hex string)", "schema": { "type": "string" } @@ -5473,40 +6557,36 @@ ], "requestBody": { "required": true, - "description": "Transaction proposal including recipient, value, data, and initial signature", + "description": "Signature proving authorization to delete the transaction", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ProposeTransactionDto" + "$ref": "#/components/schemas/DeleteTransactionDto" } } } }, "responses": { - "200": { - "description": "Transaction proposed successfully", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/TransactionDetails" - } - } - } + "204": { + "description": "Transaction deleted successfully" }, "400": { - "description": "Invalid transaction data or signature" + "description": "Invalid signature or unauthorized deletion attempt" + }, + "404": { + "description": "Transaction not found" } }, - "summary": "Propose transaction", + "summary": "Delete transaction", "tags": [ "transactions" ] } }, - "/v1/chains/{chainId}/safes/{safeAddress}/transactions/creation": { + "/v1/chains/{chainId}/safes/{safeAddress}/module-transactions": { "get": { - "description": "Retrieves the transaction that created the Safe, including the creation timestamp, creator address, factory used, and setup data.", - "operationId": "transactionsGetCreationTransactionV1", + "description": "Retrieves a paginated list of module transactions for a Safe. Module transactions are executed directly by enabled modules without requiring owner signatures.", + "operationId": "transactionsGetModuleTransactionsV1", "parameters": [ { "name": "chainId", @@ -5518,6 +6598,15 @@ "type": "string" } }, + { + "name": "cursor", + "required": false, + "in": "query", + "description": "Pagination cursor for retrieving the next set of results", + "schema": { + "type": "string" + } + }, { "name": "safeAddress", "required": true, @@ -5526,175 +6615,202 @@ "schema": { "type": "string" } + }, + { + "name": "to", + "required": false, + "in": "query", + "description": "Filter by recipient address (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "module", + "required": false, + "in": "query", + "description": "Filter by module address that executed the transaction", + "schema": { + "type": "string" + } + }, + { + "name": "transaction_hash", + "required": false, + "in": "query", + "description": "Filter by specific transaction hash", + "schema": { + "type": "string" + } } ], "responses": { "200": { - "description": "Safe creation transaction details", + "description": "Paginated list of module transactions", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/CreationTransaction" + "$ref": "#/components/schemas/ModuleTransactionPage" } } } }, - "404": { - "description": "Safe not found or creation transaction not available" + "422": { + "description": "Invalid cursor" } }, - "summary": "Get Safe creation transaction", + "summary": "Get module transactions", "tags": [ "transactions" ] } }, - "/v1/export/chains/{chainId}/{safeAddress}": { + "/v1/chains/{chainId}/transactions/{safeTxHash}/confirmations": { "post": { - "operationId": "csvExportLaunchExportV1", + "description": "Adds a confirmation signature to a pending multisig transaction. Once enough confirmations are collected to meet the Safe threshold, the transaction can be executed.", + "operationId": "transactionsAddConfirmationV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", + "description": "Chain ID where the Safe is deployed", "schema": { + "example": "1", "type": "string" } }, { - "name": "safeAddress", + "name": "safeTxHash", "required": true, "in": "path", + "description": "Safe transaction hash (0x prefixed hex string)", "schema": { "type": "string" } } ], "requestBody": { - "required": false, - "description": "Transaction export request", + "required": true, + "description": "Confirmation signature from a Safe owner proving their approval of the transaction", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/TransactionExportDto" + "$ref": "#/components/schemas/AddConfirmationDto" } } } }, "responses": { - "202": { - "description": "", + "200": { + "description": "Transaction details with updated confirmation status", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/JobStatusDto" + "$ref": "#/components/schemas/TransactionDetails" } } } + }, + "400": { + "description": "Confirmation already exists for this owner" + }, + "404": { + "description": "Transaction not found" + }, + "422": { + "description": "Invalid chainId, safeTxHash, request body or signature" } }, + "summary": "Add transaction confirmation", "tags": [ - "export" + "transactions" ] } }, - "/v1/export/{jobId}/status": { + "/v1/chains/{chainId}/safes/{safeAddress}/incoming-transfers": { "get": { - "operationId": "csvExportGetExportStatusV1", + "description": "Retrieves a paginated list of incoming transfers to a Safe, including ETH and token transfers with optional filtering by date, value, token, and trust status.", + "operationId": "transactionsGetIncomingTransfersV1", "parameters": [ { - "name": "jobId", + "name": "chainId", "required": true, "in": "path", + "description": "Chain ID where the Safe is deployed", "schema": { + "example": "1", "type": "string" } - } - ], - "responses": { - "200": { - "description": "CSV export status retrieved successfully", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/JobStatusDto" - } - } + }, + { + "name": "safeAddress", + "required": true, + "in": "path", + "description": "Safe contract address (0x prefixed hex string)", + "schema": { + "type": "string" } }, - "404": { - "description": "CSV export not found", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/JobStatusErrorDto" - } - } - } - } - }, - "tags": [ - "export" - ] - } - }, - "/v1/chains/{chainId}/delegates": { - "get": { - "deprecated": true, - "description": "Retrieves a paginated list of delegates for a specific chain. This endpoint is deprecated, please use the v2 version instead.", - "operationId": "delegatesGetDelegatesV1", - "parameters": [ { - "name": "chainId", - "required": true, - "in": "path", - "description": "Chain ID where delegates are registered", + "name": "cursor", + "required": false, + "in": "query", + "description": "Pagination cursor for retrieving the next set of results", "schema": { - "example": "1", "type": "string" } }, { - "name": "cursor", + "name": "trusted", "required": false, "in": "query", - "description": "Pagination cursor for retrieving the next set of results", + "description": "Filter by trust status (true for trusted tokens, false for untrusted)", + "schema": { + "type": "boolean" + } + }, + { + "name": "execution_date__gte", + "required": false, + "in": "query", + "description": "Filter by execution date greater than or equal to (ISO 8601 format)", "schema": { "type": "string" } }, { - "name": "label", + "name": "execution_date__lte", "required": false, "in": "query", - "description": "Filter by delegate label", + "description": "Filter by execution date less than or equal to (ISO 8601 format)", "schema": { "type": "string" } }, { - "name": "delegator", + "name": "to", "required": false, "in": "query", - "description": "Filter by delegator address", + "description": "Filter by recipient address (0x prefixed hex string)", "schema": { "type": "string" } }, { - "name": "delegate", + "name": "value", "required": false, "in": "query", - "description": "Filter by delegate address", + "description": "Filter by transfer value in wei", "schema": { "type": "string" } }, { - "name": "safe", + "name": "token_address", "required": false, "in": "query", - "description": "Filter by Safe address", + "description": "Filter by token contract address (0x prefixed hex string for ERC-20 tokens)", "schema": { "type": "string" } @@ -5702,118 +6818,132 @@ ], "responses": { "200": { - "description": "Paginated list of delegates retrieved successfully", + "description": "Paginated list of incoming transfers", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/DelegatePage" + "$ref": "#/components/schemas/IncomingTransferPage" } } } + }, + "422": { + "description": "Invalid cursor" } }, - "summary": "Get delegates (deprecated)", + "summary": "Get incoming transfers", "tags": [ - "delegates" + "transactions" ] - }, - "post": { - "deprecated": true, - "description": "Creates a new delegate for a specific chain. This endpoint is deprecated, please use the v2 version instead.", - "operationId": "delegatesPostDelegateV1", + } + }, + "/v1/chains/{chainId}/safes/{safeAddress}/outgoing-transfers": { + "get": { + "description": "Retrieves native, ERC-20 and ERC-721 transfers sent by a Safe. Unlike multisig-transactions, `to` matches the recipient of each transfer rather than the target of the Safe transaction. Token transfers made inside batches are included; native transfers made inside batches are not available on chains indexed from events (most L2s). Only the newest 1000 transfers per direction and transfer type can be reached, so narrow with filters for older history. A page can hold fewer items than requested, or none, once untrusted transfers are dropped: keep following `next` until it is null.", + "operationId": "transactionsGetOutgoingTransfersV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the delegate will be registered", + "description": "Chain ID where the Safe is deployed", "schema": { "example": "1", "type": "string" } - } - ], - "requestBody": { - "required": true, - "description": "Delegate creation data including Safe address, delegate address, and signature", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateDelegateDto" - } - } - } - }, - "responses": { - "204": { - "description": "Delegate created successfully" }, - "400": { - "description": "Invalid delegate data or signature" - } - }, - "summary": "Create delegate (deprecated)", - "tags": [ - "delegates" - ] - } - }, - "/v1/chains/{chainId}/delegates/{delegateAddress}": { - "delete": { - "deprecated": true, - "description": "Deletes a delegate for a specific chain and address. This endpoint is deprecated, please use the v2 version instead.", - "operationId": "delegatesDeleteDelegateV1", - "parameters": [ { - "name": "chainId", + "name": "safeAddress", "required": true, "in": "path", - "description": "Chain ID where the delegate is registered", + "description": "Safe contract address (0x prefixed hex string)", "schema": { - "example": "1", "type": "string" } }, { - "name": "delegateAddress", - "required": true, - "in": "path", - "description": "Delegate address to delete (0x prefixed hex string)", + "name": "cursor", + "required": false, + "in": "query", + "description": "Pagination cursor for retrieving the next set of results", + "schema": { + "type": "string" + } + }, + { + "name": "trusted", + "required": false, + "in": "query", + "description": "When true (default), ERC-20 transfers of untrusted tokens are omitted, since any token contract can emit a transfer the Safe never made. ERC-721 and native transfers are not filtered. ERC-20 transfers without value are always omitted.", + "schema": { + "type": "boolean" + } + }, + { + "name": "execution_date__gte", + "required": false, + "in": "query", + "description": "Filter by execution date greater than or equal to (ISO 8601 UTC, e.g. 2024-01-01T00:00:00Z)", + "schema": { + "type": "string" + } + }, + { + "name": "execution_date__lte", + "required": false, + "in": "query", + "description": "Filter by execution date less than or equal to (ISO 8601 UTC, e.g. 2024-01-01T00:00:00Z)", + "schema": { + "type": "string" + } + }, + { + "name": "to", + "required": false, + "in": "query", + "description": "Filter by transfer recipient address (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "token_address", + "required": false, + "in": "query", + "description": "Filter by token contract address (0x prefixed hex string)", "schema": { "type": "string" } } ], - "requestBody": { - "required": true, - "description": "Signature proving authorization to delete the delegate", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DeleteDelegateDto" + "responses": { + "200": { + "description": "Paginated list of outgoing transfers", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/TransferTransactionItemPage" + } } } - } - }, - "responses": { - "204": { - "description": "Delegate deleted successfully" }, - "400": { - "description": "Invalid signature or unauthorized deletion attempt" + "404": { + "description": "Safe or chain not found" + }, + "422": { + "description": "Invalid chain ID, address, date, trusted flag or cursor" } }, - "summary": "Delete delegate (deprecated)", + "summary": "Get outgoing transfers", "tags": [ - "delegates" + "transactions" ] } }, - "/v1/chains/{chainId}/safes/{safeAddress}/delegates/{delegateAddress}": { - "delete": { - "deprecated": true, - "description": "Removes a delegate from a specific Safe. This endpoint is deprecated, please use the v2 version instead.", - "operationId": "delegatesDeleteSafeDelegateV1", + "/v1/chains/{chainId}/transactions/{safeAddress}/preview": { + "post": { + "description": "Simulates a transaction execution to preview its effects, including gas estimates, balance changes, and potential errors before actually proposing or executing it.", + "operationId": "transactionsPreviewTransactionV1", "parameters": [ { "name": "chainId", @@ -5825,15 +6955,6 @@ "type": "string" } }, - { - "name": "delegateAddress", - "required": true, - "in": "path", - "description": "Delegate address to remove (0x prefixed hex string)", - "schema": { - "type": "string" - } - }, { "name": "safeAddress", "required": true, @@ -5846,167 +6967,215 @@ ], "requestBody": { "required": true, - "description": "Signature proving authorization to remove the delegate", + "description": "Transaction data to preview including recipient, value, data, and operation type", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/DeleteSafeDelegateDto" + "$ref": "#/components/schemas/PreviewTransactionDto" } } } }, "responses": { - "204": { - "description": "Safe delegate removed successfully" + "200": { + "description": "Transaction preview with simulation results, gas estimates, and potential effects", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/TransactionPreview" + } + } + } }, "400": { - "description": "Invalid signature or unauthorized removal attempt" + "description": "Invalid transaction data or simulation failed" + }, + "404": { + "description": "Safe not found" } }, - "summary": "Delete Safe delegate (deprecated)", + "summary": "Preview transaction", "tags": [ - "delegates" + "transactions" ] } }, - "/v2/chains/{chainId}/delegates": { + "/v1/chains/{chainId}/safes/{safeAddress}/transactions/queued": { "get": { - "description": "Retrieves a paginated list of delegates for a specific chain with optional filtering by Safe, delegate, delegator, or label.", - "operationId": "delegatesGetDelegatesV2", + "description": "Retrieves a paginated list of queued (pending) transactions for a Safe that are waiting for execution, ordered by nonce.", + "operationId": "transactionsGetTransactionQueueV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where delegates are registered", + "description": "Chain ID where the Safe is deployed", "schema": { "example": "1", "type": "string" } }, { - "name": "cursor", - "required": false, - "in": "query", - "description": "Pagination cursor for retrieving the next set of results", + "name": "safeAddress", + "required": true, + "in": "path", + "description": "Safe contract address (0x prefixed hex string)", "schema": { "type": "string" } }, { - "name": "label", + "name": "cursor", "required": false, "in": "query", - "description": "Filter by delegate label or name", + "description": "Pagination cursor for retrieving the next set of results", "schema": { "type": "string" } }, { - "name": "delegator", + "name": "trusted", "required": false, "in": "query", - "description": "Filter by delegator address (0x prefixed hex string)", + "description": "Filter by trust status (true for trusted transactions, false for untrusted)", "schema": { - "type": "string" - } - }, - { - "name": "delegate", - "required": false, - "in": "query", - "description": "Filter by delegate address (0x prefixed hex string)", - "schema": { - "type": "string" - } - }, - { - "name": "safe", - "required": false, - "in": "query", - "description": "Filter by Safe address (0x prefixed hex string)", - "schema": { - "type": "string" + "type": "boolean" } } ], "responses": { "200": { - "description": "Paginated list of delegates retrieved successfully", + "description": "Paginated list of queued transactions", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/DelegatePage" + "$ref": "#/components/schemas/QueuedItemPage" } } } + }, + "422": { + "description": "Invalid cursor" } }, - "summary": "Get delegates", + "summary": "Get transaction queue", "tags": [ - "delegates" + "transactions" ] - }, - "post": { - "description": "Creates a new delegate relationship between a Safe and a delegate address. Requires proper authorization signature.", - "operationId": "delegatesPostDelegateV2", + } + }, + "/v1/chains/{chainId}/safes/{safeAddress}/transactions/history": { + "get": { + "description": "Retrieves a paginated list of executed transactions for a Safe, including multisig transactions, module transactions, and incoming transfers, ordered by execution date.", + "operationId": "transactionsGetTransactionsHistoryV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the delegate will be registered", + "description": "Chain ID where the Safe is deployed", "schema": { "example": "1", "type": "string" } + }, + { + "name": "safeAddress", + "required": true, + "in": "path", + "description": "Safe contract address (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "cursor", + "required": false, + "in": "query", + "description": "Pagination cursor for retrieving the next set of results", + "schema": { + "type": "string" + } + }, + { + "name": "timezone_offset", + "required": false, + "in": "query", + "deprecated": true, + "description": "Deprecated: Timezone offset in milliseconds for date formatting (use timezone parameter instead)", + "schema": { + "type": "string" + } + }, + { + "name": "trusted", + "required": false, + "in": "query", + "description": "Filter by trust status (default: true, set to false to include untrusted transactions)", + "schema": { + "type": "boolean" + } + }, + { + "name": "imitation", + "required": false, + "in": "query", + "description": "Include imitation transactions in results (default: true, set to false to exclude)", + "schema": { + "type": "boolean" + } + }, + { + "name": "timezone", + "required": false, + "in": "query", + "description": "IANA timezone identifier for date formatting (e.g., \"America/New_York\")", + "schema": { + "type": "string" + } } ], - "requestBody": { - "required": true, - "description": "Delegate creation data including Safe address, delegate address, label, and authorization signature", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateDelegateDto" + "responses": { + "200": { + "description": "Paginated list of historical transactions", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/TransactionItemPage" + } } } - } - }, - "responses": { - "204": { - "description": "Delegate created successfully" }, - "400": { - "description": "Invalid delegate data, signature, or unauthorized creation attempt" + "422": { + "description": "Invalid cursor" } }, - "summary": "Create delegate", + "summary": "Get transaction history", "tags": [ - "delegates" + "transactions" ] } }, - "/v2/chains/{chainId}/delegates/{delegateAddress}": { - "delete": { - "description": "Removes a delegate relationship for a specific delegate address. Requires proper authorization signature.", - "operationId": "delegatesDeleteDelegateV2", + "/v1/chains/{chainId}/transactions/{safeAddress}/propose": { + "post": { + "description": "Proposes a new multisig transaction for a Safe. The transaction will be pending until enough owners sign it to reach the required threshold.", + "operationId": "transactionsProposeTransactionV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the delegate is registered", + "description": "Chain ID where the Safe is deployed", "schema": { "example": "1", "type": "string" } }, { - "name": "delegateAddress", + "name": "safeAddress", "required": true, "in": "path", - "description": "Delegate address to remove (0x prefixed hex string)", + "description": "Safe contract address (0x prefixed hex string)", "schema": { "type": "string" } @@ -6014,121 +7183,94 @@ ], "requestBody": { "required": true, - "description": "Signature and data proving authorization to delete the delegate", + "description": "Transaction proposal including recipient, value, data, and initial signature", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/DeleteDelegateV2Dto" + "$ref": "#/components/schemas/ProposeTransactionDto" } } } }, "responses": { - "204": { - "description": "Delegate deleted successfully" - }, - "400": { - "description": "Invalid signature or unauthorized deletion attempt" - } - }, - "summary": "Delete delegate", - "tags": [ - "delegates" - ] - } - }, - "/v1/register/notifications": { - "post": { - "deprecated": true, - "description": "Registers a device to receive push notifications for Safe events. This endpoint is deprecated, please use the v2 version instead.", - "operationId": "notificationsRegisterDeviceV1", - "parameters": [], - "requestBody": { - "required": true, - "description": "Device registration data including device token, UUID, and Safe registrations with signatures", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RegisterDeviceDto" + "200": { + "description": "Transaction proposed successfully", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/TransactionDetails" + } } } - } - }, - "responses": { - "200": { - "description": "Device registered successfully for notifications" }, "400": { - "description": "Invalid device data, expired timestamp, or invalid signature" + "description": "Invalid transaction data" + }, + "422": { + "description": "Invalid chainId, safeAddress, request body or signature" } }, - "summary": "Register device for notifications (deprecated)", + "summary": "Propose transaction", "tags": [ - "notifications" + "transactions" ] } }, - "/v1/chains/{chainId}/notifications/devices/{uuid}": { - "delete": { - "deprecated": true, - "description": "Removes a device from receiving notifications. This endpoint is deprecated, please use the v2 version instead.", - "operationId": "notificationsUnregisterDeviceV1", + "/v1/chains/{chainId}/safes/{safeAddress}/transactions/creation": { + "get": { + "description": "Retrieves the transaction that created the Safe, including the creation timestamp, creator address, factory used, and setup data.", + "operationId": "transactionsGetCreationTransactionV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID (kept for backward compatibility)", + "description": "Chain ID where the Safe is deployed", "schema": { "example": "1", "type": "string" } }, { - "name": "uuid", + "name": "safeAddress", "required": true, "in": "path", - "description": "Device UUID to unregister", + "description": "Safe contract address (0x prefixed hex string)", "schema": { - "example": "550e8400-e29b-41d4-a716-446655440000", "type": "string" } } ], "responses": { - "204": { - "description": "Device unregistered successfully" + "200": { + "description": "Safe creation transaction details", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreationTransaction" + } + } + } + }, + "404": { + "description": "Safe not found or creation transaction not available" } }, - "summary": "Unregister device (deprecated)", + "summary": "Get Safe creation transaction", "tags": [ - "notifications" + "transactions" ] } }, - "/v1/chains/{chainId}/notifications/devices/{uuid}/safes/{safeAddress}": { - "delete": { - "deprecated": true, - "description": "Removes a specific Safe from receiving notifications on a device. This endpoint is deprecated, please use the v2 version instead.", - "operationId": "notificationsUnregisterSafeV1", + "/v1/export/chains/{chainId}/{safeAddress}": { + "post": { + "operationId": "csvExportLaunchExportV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", - "schema": { - "example": "1", - "type": "string" - } - }, - { - "name": "uuid", - "required": true, - "in": "path", - "description": "Device UUID", "schema": { - "example": "550e8400-e29b-41d4-a716-446655440000", "type": "string" } }, @@ -6136,97 +7278,136 @@ "name": "safeAddress", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", "schema": { "type": "string" } } ], - "responses": { - "204": { - "description": "Safe unregistered from device notifications successfully" + "requestBody": { + "required": false, + "description": "Transaction export request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/TransactionExportDto" + } + } } }, - "summary": "Unregister Safe from device (deprecated)", - "tags": [ - "notifications" - ] - } - }, - "/v2/register/notifications": { - "post": { - "description": "Registers or updates a device to receive push notifications for Safe events. Creates subscriptions for specified Safes and notification types.", - "operationId": "notificationsUpsertSubscriptionsV2", - "parameters": [], - "requestBody": { - "required": true, - "description": "Device and subscription data including device token, Safe addresses, and notification preferences", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpsertSubscriptionsDto" + "responses": { + "202": { + "description": "", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/JobStatusDto" + } } } } }, + "tags": [ + "export" + ] + } + }, + "/v1/export/{jobId}/status": { + "get": { + "operationId": "csvExportGetExportStatusV1", + "parameters": [ + { + "name": "jobId", + "required": true, + "in": "path", + "schema": { + "type": "string" + } + } + ], "responses": { - "201": { - "description": "Device registered successfully with returned device UUID", + "200": { + "description": "CSV export status retrieved successfully", "content": { "application/json": { "schema": { - "type": "object", - "properties": { - "deviceUuid": { - "type": "string", - "format": "uuid", - "description": "Generated UUID for the registered device" - } - } + "$ref": "#/components/schemas/JobStatusDto" } } } }, - "400": { - "description": "Invalid device data or subscription configuration" + "404": { + "description": "CSV export not found", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/JobStatusErrorDto" + } + } + } } }, - "summary": "Register device for notifications", "tags": [ - "notifications" + "export" ] } }, - "/v2/chains/{chainId}/notifications/devices/{deviceUuid}/safes/{safeAddress}": { + "/v1/chains/{chainId}/delegates": { "get": { - "description": "Retrieves the notification types that a device is subscribed to for a specific Safe.", - "operationId": "notificationsGetSafeSubscriptionV2", + "deprecated": true, + "description": "Retrieves a paginated list of delegates for a specific chain. This endpoint is deprecated, please use the v3 version instead.", + "operationId": "delegatesGetDelegatesV1", "parameters": [ { - "name": "deviceUuid", + "name": "chainId", "required": true, "in": "path", - "description": "Device UUID", + "description": "Chain ID where delegates are registered", "schema": { - "example": "550e8400-e29b-41d4-a716-446655440000", + "example": "1", "type": "string" } }, { - "name": "chainId", - "required": true, - "in": "path", - "description": "Chain ID where the Safe is deployed", + "name": "cursor", + "required": false, + "in": "query", + "description": "Pagination cursor for retrieving the next set of results", "schema": { - "example": "1", "type": "string" } }, { - "name": "safeAddress", - "required": true, - "in": "path", - "description": "Safe contract address (0x prefixed hex string)", + "name": "label", + "required": false, + "in": "query", + "description": "Filter by delegate label", + "schema": { + "type": "string" + } + }, + { + "name": "delegator", + "required": false, + "in": "query", + "description": "Filter by delegator address", + "schema": { + "type": "string" + } + }, + { + "name": "delegate", + "required": false, + "in": "query", + "description": "Filter by delegate address", + "schema": { + "type": "string" + } + }, + { + "name": "safe", + "required": false, + "in": "query", + "description": "Filter by Safe address", "schema": { "type": "string" } @@ -6234,2568 +7415,5269 @@ ], "responses": { "200": { - "description": "List of notification types the device is subscribed to for this Safe", + "description": "Paginated list of delegates retrieved successfully", "content": { "application/json": { "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/NotificationTypeResponseDto" - } + "$ref": "#/components/schemas/DelegatePage" } } } }, - "401": { - "description": "Authentication required - valid JWT token must be provided" - }, - "404": { - "description": "Device, Safe, or subscription not found" + "422": { + "description": "Invalid cursor" } }, - "summary": "Get Safe subscription", + "summary": "Get delegates (deprecated)", "tags": [ - "notifications" + "delegates" ] }, - "delete": { - "description": "Removes all notification subscriptions for a specific Safe on a device.", - "operationId": "notificationsDeleteSubscriptionV2", + "post": { + "deprecated": true, + "description": "Creates a new delegate for a specific chain. This endpoint is deprecated, please use the v3 version instead.", + "operationId": "delegatesPostDelegateV1", "parameters": [ { - "name": "deviceUuid", + "name": "chainId", "required": true, "in": "path", - "description": "Device UUID", + "description": "Chain ID where the delegate will be registered", "schema": { - "example": "550e8400-e29b-41d4-a716-446655440000", + "example": "1", "type": "string" } + } + ], + "requestBody": { + "required": true, + "description": "Delegate creation data including Safe address, delegate address, and signature", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateDelegateDto" + } + } + } + }, + "responses": { + "204": { + "description": "Delegate created successfully" }, + "400": { + "description": "Invalid delegate data or signature" + } + }, + "summary": "Create delegate (deprecated)", + "tags": [ + "delegates" + ] + } + }, + "/v1/chains/{chainId}/delegates/{delegateAddress}": { + "delete": { + "deprecated": true, + "description": "Deletes a delegate for a specific chain and address. This endpoint is deprecated, please use the v3 version instead.", + "operationId": "delegatesDeleteDelegateV1", + "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID where the Safe is deployed", + "description": "Chain ID where the delegate is registered", "schema": { "example": "1", "type": "string" } }, { - "name": "safeAddress", + "name": "delegateAddress", "required": true, "in": "path", - "description": "Safe contract address (0x prefixed hex string)", + "description": "Delegate address to delete (0x prefixed hex string)", "schema": { "type": "string" } } ], - "responses": { - "204": { - "description": "Safe subscription deleted successfully" - }, - "404": { - "description": "Device, Safe, or subscription not found" - } - }, - "summary": "Delete Safe subscription", - "tags": [ - "notifications" - ] - } - }, - "/v2/notifications/subscriptions": { - "delete": { - "description": "Delete all subscriptions of a Safe on a device. This will delete all subscriptions of a Safe on a device for all chains passed in the request body.", - "operationId": "notificationsDeleteAllSubscriptionsV2", - "parameters": [], "requestBody": { "required": true, + "description": "Signature proving authorization to delete the delegate", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/DeleteAllSubscriptionsDto" + "$ref": "#/components/schemas/DeleteDelegateDto" } } } }, "responses": { - "404": { - "description": "No subscription was found" + "204": { + "description": "Delegate deleted successfully" }, - "422": { - "description": "The request body is invalid" + "400": { + "description": "Invalid signature or unauthorized deletion attempt" } }, - "summary": "Delete all subscriptions of a device", + "summary": "Delete delegate (deprecated)", "tags": [ - "notifications" + "delegates" ] } }, - "/v2/chains/{chainId}/notifications/devices/{deviceUuid}": { + "/v1/chains/{chainId}/safes/{safeAddress}/delegates/{delegateAddress}": { "delete": { - "description": "Removes a device and all its notification subscriptions from the system.", - "operationId": "notificationsDeleteDeviceV2", + "deprecated": true, + "description": "Removes a delegate from a specific Safe. This endpoint is deprecated, please use the v3 version instead.", + "operationId": "delegatesDeleteSafeDelegateV1", "parameters": [ { "name": "chainId", "required": true, "in": "path", - "description": "Chain ID (kept for backward compatibility)", + "description": "Chain ID where the Safe is deployed", "schema": { "example": "1", "type": "string" } }, { - "name": "deviceUuid", + "name": "delegateAddress", "required": true, "in": "path", - "description": "Device UUID to delete", + "description": "Delegate address to remove (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "safeAddress", + "required": true, + "in": "path", + "description": "Safe contract address (0x prefixed hex string)", "schema": { - "example": "550e8400-e29b-41d4-a716-446655440000", "type": "string" } } ], + "requestBody": { + "required": true, + "description": "Signature proving authorization to remove the delegate", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/DeleteSafeDelegateDto" + } + } + } + }, "responses": { "204": { - "description": "Device deleted successfully" + "description": "Safe delegate removed successfully" + }, + "400": { + "description": "Invalid signature or unauthorized removal attempt" + } + }, + "summary": "Delete Safe delegate (deprecated)", + "tags": [ + "delegates" + ] + } + }, + "/v2/chains/{chainId}/delegates": { + "get": { + "deprecated": true, + "description": "Retrieves a paginated list of delegates for a specific chain with optional filtering by Safe, delegate, delegator, or label. This endpoint is deprecated, please use the v3 version instead.", + "operationId": "delegatesGetDelegatesV2", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where delegates are registered", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "cursor", + "required": false, + "in": "query", + "description": "Pagination cursor for retrieving the next set of results", + "schema": { + "type": "string" + } + }, + { + "name": "label", + "required": false, + "in": "query", + "description": "Filter by delegate label or name", + "schema": { + "type": "string" + } + }, + { + "name": "delegator", + "required": false, + "in": "query", + "description": "Filter by delegator address (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "delegate", + "required": false, + "in": "query", + "description": "Filter by delegate address (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "safe", + "required": false, + "in": "query", + "description": "Filter by Safe address (0x prefixed hex string)", + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "Paginated list of delegates retrieved successfully", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/DelegatePage" + } + } + } + }, + "422": { + "description": "Invalid cursor" + } + }, + "summary": "Get delegates (deprecated)", + "tags": [ + "delegates" + ] + }, + "post": { + "deprecated": true, + "description": "Creates a new delegate relationship between a Safe and a delegate address. Requires proper authorization signature. This endpoint is deprecated, please use the v3 version instead.", + "operationId": "delegatesPostDelegateV2", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the delegate will be registered", + "schema": { + "example": "1", + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "description": "Delegate creation data including Safe address, delegate address, label, and authorization signature", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateDelegateDto" + } + } + } + }, + "responses": { + "204": { + "description": "Delegate created successfully" + }, + "400": { + "description": "Invalid delegate data, signature, or unauthorized creation attempt" + } + }, + "summary": "Create delegate (deprecated)", + "tags": [ + "delegates" + ] + } + }, + "/v2/chains/{chainId}/delegates/{delegateAddress}": { + "delete": { + "deprecated": true, + "description": "Removes a delegate relationship for a specific delegate address. Requires proper authorization signature. This endpoint is deprecated, please use the v3 version instead.", + "operationId": "delegatesDeleteDelegateV2", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the delegate is registered", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "delegateAddress", + "required": true, + "in": "path", + "description": "Delegate address to remove (0x prefixed hex string)", + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "description": "Signature and data proving authorization to delete the delegate", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/DeleteDelegateV2Dto" + } + } + } + }, + "responses": { + "204": { + "description": "Delegate deleted successfully" + }, + "400": { + "description": "Invalid signature or unauthorized deletion attempt" + } + }, + "summary": "Delete delegate (deprecated)", + "tags": [ + "delegates" + ] + } + }, + "/v3/chains/{chainId}/delegates": { + "get": { + "description": "Retrieves a paginated list of delegates for a specific chain with optional filtering by Safe, delegate, delegator, or label.", + "operationId": "delegatesGetDelegatesV3", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where delegates are registered", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "cursor", + "required": false, + "in": "query", + "description": "Pagination cursor for retrieving the next set of results", + "schema": { + "type": "string" + } + }, + { + "name": "label", + "required": false, + "in": "query", + "description": "Filter by delegate label or name", + "schema": { + "type": "string" + } + }, + { + "name": "delegator", + "required": false, + "in": "query", + "description": "Filter by delegator address (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "delegate", + "required": false, + "in": "query", + "description": "Filter by delegate address (0x prefixed hex string)", + "schema": { + "type": "string" + } + }, + { + "name": "safe", + "required": false, + "in": "query", + "description": "Filter by Safe address (0x prefixed hex string)", + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "Paginated list of delegates retrieved successfully", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/DelegatePage" + } + } + } + }, + "422": { + "description": "Invalid cursor" + } + }, + "summary": "Get delegates", + "tags": [ + "delegates" + ] + }, + "post": { + "description": "Creates a new delegate relationship between a Safe and a delegate address. Requires proper authorization signature.", + "operationId": "delegatesPostDelegateV3", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the delegate will be registered", + "schema": { + "example": "1", + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "description": "Delegate creation data including Safe address, delegate address, label, and authorization signature", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateDelegateDto" + } + } + } + }, + "responses": { + "204": { + "description": "Delegate created successfully" + }, + "400": { + "description": "Invalid delegate data, signature, or unauthorized creation attempt" + } + }, + "summary": "Create delegate", + "tags": [ + "delegates" + ] + }, + "patch": { + "description": "Updates an existing delegate relationship (e.g. the delegate label). Requires proper authorization signature. Depending on the backing service, a relationship that does not exist yet is either created or rejected.", + "operationId": "delegatesUpdateDelegateV3", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the delegate is registered", + "schema": { + "example": "1", + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "description": "Delegate update data including Safe address, delegate address, delegator, label, and authorization signature", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UpdateDelegateV3Dto" + } + } + } + }, + "responses": { + "204": { + "description": "Delegate updated successfully" + }, + "400": { + "description": "Invalid delegate data, signature, or unauthorized update attempt" + } + }, + "summary": "Update delegate", + "tags": [ + "delegates" + ] + } + }, + "/v3/chains/{chainId}/delegates/{delegateAddress}": { + "delete": { + "description": "Removes a delegate relationship for a specific delegate address. Requires proper authorization signature.", + "operationId": "delegatesDeleteDelegateV3", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the delegate is registered", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "delegateAddress", + "required": true, + "in": "path", + "description": "Delegate address to remove (0x prefixed hex string)", + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "description": "Signature and data proving authorization to delete the delegate", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/DeleteDelegateV3Dto" + } + } + } + }, + "responses": { + "204": { + "description": "Delegate deleted successfully" + }, + "400": { + "description": "Invalid signature or unauthorized deletion attempt" + } + }, + "summary": "Delete delegate", + "tags": [ + "delegates" + ] + } + }, + "/v1/chains/{chainId}/tokens/{address}": { + "get": { + "description": "Symbol, name, decimals, logo and trust flag of a token on the given chain, as known by the Transaction Service.", + "operationId": "tokensGetTokenV1", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID the token is deployed on", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "address", + "required": true, + "in": "path", + "description": "Token contract address (0x prefixed hex string)", + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "Token metadata", + "content": { + "application/json": { + "schema": { + "oneOf": [ + { + "$ref": "#/components/schemas/NativeTokenMetadata" + }, + { + "$ref": "#/components/schemas/Erc20TokenMetadata" + }, + { + "$ref": "#/components/schemas/Erc721TokenMetadata" + } + ] + } + } + } + }, + "404": { + "description": "The Transaction Service does not know this token" + }, + "422": { + "description": "Invalid chain ID or address" + }, + "429": { + "description": "Rate limit exceeded" + } + }, + "summary": "Get token metadata", + "tags": [ + "tokens" + ] + } + }, + "/v1/chains/{chainId}/tokens": { + "get": { + "description": "Metadata for up to 20 tokens of one chain, in request order. Addresses the Transaction Service does not know are omitted.", + "operationId": "tokensGetTokensV1", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID the token is deployed on", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "addresses", + "required": true, + "in": "query", + "description": "Comma-separated token contract addresses, at most 20", + "schema": { + "example": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48,0xdAC17F958D2ee523a2206206994597C13D831ec7", + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "Token metadata for the known addresses, in request order", + "content": { + "application/json": { + "schema": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/NativeTokenMetadata" + }, + { + "$ref": "#/components/schemas/Erc20TokenMetadata" + }, + { + "$ref": "#/components/schemas/Erc721TokenMetadata" + } + ] + } + } + } + } + }, + "422": { + "description": "Invalid chain ID, malformed address, empty list or more than 20 addresses" + }, + "429": { + "description": "Rate limit exceeded" + } + }, + "summary": "Get metadata for several tokens", + "tags": [ + "tokens" + ] + } + }, + "/v1/register/notifications": { + "post": { + "deprecated": true, + "description": "Registers a device to receive push notifications for Safe events. This endpoint is deprecated, please use the v2 version instead.", + "operationId": "notificationsRegisterDeviceV1", + "parameters": [], + "requestBody": { + "required": true, + "description": "Device registration data including device token, UUID, and Safe registrations with signatures", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RegisterDeviceDto" + } + } + } + }, + "responses": { + "200": { + "description": "Device registered successfully for notifications" + }, + "400": { + "description": "Expired timestamp" + }, + "422": { + "description": "Invalid device data or malformed signature" + } + }, + "summary": "Register device for notifications (deprecated)", + "tags": [ + "notifications" + ] + } + }, + "/v1/chains/{chainId}/notifications/devices/{uuid}": { + "delete": { + "deprecated": true, + "description": "Removes a device from receiving notifications. This endpoint is deprecated, please use the v2 version instead.", + "operationId": "notificationsUnregisterDeviceV1", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID (kept for backward compatibility)", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "uuid", + "required": true, + "in": "path", + "description": "Device UUID to unregister", + "schema": { + "example": "550e8400-e29b-41d4-a716-446655440000", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "Device unregistered successfully" + } + }, + "summary": "Unregister device (deprecated)", + "tags": [ + "notifications" + ] + } + }, + "/v1/chains/{chainId}/notifications/devices/{uuid}/safes/{safeAddress}": { + "delete": { + "deprecated": true, + "description": "Removes a specific Safe from receiving notifications on a device. This endpoint is deprecated, please use the v2 version instead.", + "operationId": "notificationsUnregisterSafeV1", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the Safe is deployed", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "uuid", + "required": true, + "in": "path", + "description": "Device UUID", + "schema": { + "example": "550e8400-e29b-41d4-a716-446655440000", + "type": "string" + } + }, + { + "name": "safeAddress", + "required": true, + "in": "path", + "description": "Safe contract address (0x prefixed hex string)", + "schema": { + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "Safe unregistered from device notifications successfully" + } + }, + "summary": "Unregister Safe from device (deprecated)", + "tags": [ + "notifications" + ] + } + }, + "/v2/register/notifications": { + "post": { + "description": "Registers or updates a device to receive push notifications for Safe events. Creates subscriptions for specified Safes and notification types.", + "operationId": "notificationsUpsertSubscriptionsV2", + "parameters": [], + "requestBody": { + "required": true, + "description": "Device and subscription data including device token, Safe addresses, and notification preferences", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UpsertSubscriptionsDto" + } + } + } + }, + "responses": { + "201": { + "description": "Device registered successfully with returned device UUID", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "deviceUuid": { + "type": "string", + "format": "uuid", + "description": "Generated UUID for the registered device" + } + } + } + } + } + }, + "400": { + "description": "Invalid device data or subscription configuration" + } + }, + "summary": "Register device for notifications", + "tags": [ + "notifications" + ] + } + }, + "/v2/chains/{chainId}/notifications/devices/{deviceUuid}/safes/{safeAddress}": { + "get": { + "description": "Retrieves the notification types that a device is subscribed to for a specific Safe.", + "operationId": "notificationsGetSafeSubscriptionV2", + "parameters": [ + { + "name": "deviceUuid", + "required": true, + "in": "path", + "description": "Device UUID", + "schema": { + "example": "550e8400-e29b-41d4-a716-446655440000", + "type": "string" + } + }, + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the Safe is deployed", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "safeAddress", + "required": true, + "in": "path", + "description": "Safe contract address (0x prefixed hex string)", + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "List of notification types the device is subscribed to for this Safe", + "content": { + "application/json": { + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/NotificationTypeResponseDto" + } + } + } + } + }, + "401": { + "description": "Authentication required - valid JWT token must be provided" + }, + "404": { + "description": "Device, Safe, or subscription not found" + } + }, + "summary": "Get Safe subscription", + "tags": [ + "notifications" + ] + }, + "delete": { + "description": "Removes all notification subscriptions for a specific Safe on a device.", + "operationId": "notificationsDeleteSubscriptionV2", + "parameters": [ + { + "name": "deviceUuid", + "required": true, + "in": "path", + "description": "Device UUID", + "schema": { + "example": "550e8400-e29b-41d4-a716-446655440000", + "type": "string" + } + }, + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID where the Safe is deployed", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "safeAddress", + "required": true, + "in": "path", + "description": "Safe contract address (0x prefixed hex string)", + "schema": { + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "Safe subscription deleted successfully" + }, + "404": { + "description": "Device, Safe, or subscription not found" + } + }, + "summary": "Delete Safe subscription", + "tags": [ + "notifications" + ] + } + }, + "/v2/notifications/subscriptions": { + "delete": { + "description": "Delete all subscriptions of a Safe on a device. This will delete all subscriptions of a Safe on a device for all chains passed in the request body.", + "operationId": "notificationsDeleteAllSubscriptionsV2", + "parameters": [], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/DeleteAllSubscriptionsDto" + } + } + } + }, + "responses": { + "404": { + "description": "No subscription was found" + }, + "422": { + "description": "The request body is invalid" + } + }, + "summary": "Delete all subscriptions of a device", + "tags": [ + "notifications" + ] + } + }, + "/v2/chains/{chainId}/notifications/devices/{deviceUuid}": { + "delete": { + "description": "Removes a device and all its notification subscriptions from the system.", + "operationId": "notificationsDeleteDeviceV2", + "parameters": [ + { + "name": "chainId", + "required": true, + "in": "path", + "description": "Chain ID (kept for backward compatibility)", + "schema": { + "example": "1", + "type": "string" + } + }, + { + "name": "deviceUuid", + "required": true, + "in": "path", + "description": "Device UUID to delete", + "schema": { + "example": "550e8400-e29b-41d4-a716-446655440000", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "Device deleted successfully" }, "404": { "description": "Device not found" } }, - "summary": "Delete device", - "tags": [ - "notifications" + "summary": "Delete device", + "tags": [ + "notifications" + ] + } + } + }, + "info": { + "title": "Safe Client Gateway", + "description": "", + "version": "main-4657207", + "contact": {} + }, + "tags": [], + "servers": [], + "components": { + "schemas": { + "About": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "version": { + "type": "string", + "nullable": true + }, + "buildNumber": { + "type": "string", + "nullable": true + } + }, + "required": [ + "name" + ] + }, + "UserSession": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "authMethod": { + "type": "string", + "enum": [ + "siwe", + "oidc" + ] + }, + "signerAddress": { + "type": "string", + "description": "Wallet signer address. Present only for SIWE-authenticated users." + }, + "email": { + "type": "string", + "description": "Verified email address. Present only for OIDC-authenticated users when stored." + } + }, + "required": [ + "id", + "authMethod" + ] + }, + "AuthNonce": { + "type": "object", + "properties": { + "nonce": { + "type": "string" + } + }, + "required": [ + "nonce" + ] + }, + "SiweDto": { + "type": "object", + "properties": { + "message": { + "type": "string" + }, + "signature": { + "type": "string" + } + }, + "required": [ + "message", + "signature" + ] + }, + "LogoutDto": { + "type": "object", + "properties": { + "redirect_url": { + "type": "string", + "description": "Post-logout redirect URL (must be same-origin as pre-configured URL)" + } + } + }, + "Authenticator": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "Auth0 authentication method identifier (e.g. totp|...)" + }, + "type": { + "type": "string", + "description": "Authentication method type (e.g. totp)" + }, + "name": { + "type": "string", + "description": "User-visible authenticator name" + }, + "createdAt": { + "type": "string", + "description": "ISO 8601 timestamp of when the method was enrolled" + } + }, + "required": [ + "id", + "type" + ] + }, + "NativeToken": { + "type": "object", + "properties": { + "address": { + "type": "string" + }, + "decimals": { + "type": "number" + }, + "logoUri": { + "type": "string" + }, + "name": { + "type": "string" + }, + "symbol": { + "type": "string" + }, + "type": { + "type": "string", + "enum": [ + "NATIVE_TOKEN" + ] + } + }, + "required": [ + "address", + "decimals", + "logoUri", + "name", + "symbol", + "type" + ] + }, + "Erc20Token": { + "type": "object", + "properties": { + "address": { + "type": "string" + }, + "decimals": { + "type": "number" + }, + "logoUri": { + "type": "string" + }, + "name": { + "type": "string" + }, + "symbol": { + "type": "string" + }, + "type": { + "type": "string", + "enum": [ + "ERC20" + ] + } + }, + "required": [ + "address", + "decimals", + "logoUri", + "name", + "symbol", + "type" + ] + }, + "Erc721Token": { + "type": "object", + "properties": { + "address": { + "type": "string" + }, + "decimals": { + "type": "number" + }, + "logoUri": { + "type": "string" + }, + "name": { + "type": "string" + }, + "symbol": { + "type": "string" + }, + "type": { + "type": "string", + "enum": [ + "ERC721" + ] + } + }, + "required": [ + "address", + "decimals", + "logoUri", + "name", + "symbol", + "type" + ] + }, + "Balance": { + "type": "object", + "properties": { + "balance": { + "type": "string" + }, + "fiatBalance": { + "type": "string" + }, + "fiatConversion": { + "type": "string" + }, + "tokenInfo": { + "oneOf": [ + { + "$ref": "#/components/schemas/NativeToken" + }, + { + "$ref": "#/components/schemas/Erc20Token" + }, + { + "$ref": "#/components/schemas/Erc721Token" + } + ] + }, + "fiatBalance24hChange": { + "type": "string", + "nullable": true + } + }, + "required": [ + "balance", + "fiatBalance", + "fiatConversion", + "tokenInfo" + ] + }, + "Balances": { + "type": "object", + "properties": { + "fiatTotal": { + "type": "string" + }, + "items": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/Balance" + } + ] + } + } + }, + "required": [ + "fiatTotal", + "items" + ] + }, + "SubscriptionPlan": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "name": { + "type": "string", + "nullable": true + }, + "description": { + "type": "string", + "nullable": true + }, + "currentPrice": { + "type": "number" + }, + "originalPrice": { + "type": "number", + "nullable": true + }, + "paymentMethod": { + "type": "string" + }, + "currency": { + "type": "string" + }, + "features": { + "type": "array", + "items": { + "type": "string" + } + }, + "billingCycle": { + "type": "string", + "nullable": true + }, + "type": { + "type": "string" + }, + "product": { + "type": "string", + "nullable": true + } + }, + "required": [ + "id", + "currentPrice", + "originalPrice", + "paymentMethod", + "currency", + "features", + "type", + "product" + ] + }, + "Subscription": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "customerId": { + "type": "string" + }, + "upstreamCustomerId": { + "type": "string" + }, + "plan": { + "$ref": "#/components/schemas/SubscriptionPlan" + }, + "status": { + "type": "string", + "enum": [ + "active", + "canceled", + "incomplete", + "incomplete_expired", + "past_due", + "paused", + "trialing", + "unpaid" + ] + }, + "createdAt": { + "type": "number" + }, + "startAt": { + "type": "number" + }, + "cancelledAt": { + "type": "number", + "nullable": true + }, + "cancelAt": { + "type": "number", + "nullable": true + }, + "currentPeriodStart": { + "type": "number", + "nullable": true + }, + "currentPeriodEnd": { + "type": "number", + "nullable": true + }, + "metadata": { + "type": "object", + "nullable": true + }, + "hasPaymentMethod": { + "type": "boolean", + "description": "Whether the subscription has a default payment method, or its customer does as a fallback" + } + }, + "required": [ + "id", + "customerId", + "upstreamCustomerId", + "plan", + "status", + "createdAt", + "startAt", + "cancelledAt", + "cancelAt" + ] + }, + "PaymentLink": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "active": { + "type": "boolean" + }, + "metadata": { + "type": "object" + }, + "customText": { + "type": "object" + }, + "afterCompletion": { + "type": "object" + }, + "lineItems": { + "type": "array", + "items": { + "type": "object" + } + }, + "trialPeriodDays": { + "type": "number", + "nullable": true + } + }, + "required": [ + "id", + "active", + "metadata" + ] + }, + "MarketingFeature": { + "type": "object", + "properties": { + "name": { + "type": "string" + } + }, + "required": [ + "name" + ] + }, + "Product": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "active": { + "type": "boolean" + }, + "description": { + "type": "string" + }, + "marketingFeatures": { + "type": "array", + "items": { + "$ref": "#/components/schemas/MarketingFeature" + } + }, + "metadata": { + "type": "object" + }, + "name": { + "type": "string" + } + }, + "required": [ + "id", + "active", + "description", + "marketingFeatures", + "metadata", + "name" + ] + }, + "Plan": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "name": { + "type": "string", + "nullable": true + }, + "description": { + "type": "string", + "nullable": true + }, + "currentPrice": { + "type": "number" + }, + "originalPrice": { + "type": "number", + "nullable": true + }, + "paymentMethod": { + "type": "string" + }, + "currency": { + "type": "string" + }, + "features": { + "type": "array", + "items": { + "type": "string" + } + }, + "billingCycle": { + "type": "string", + "nullable": true + }, + "type": { + "type": "string" + }, + "product": { + "$ref": "#/components/schemas/Product" + } + }, + "required": [ + "id", + "currentPrice", + "originalPrice", + "paymentMethod", + "currency", + "features", + "type", + "product" + ] + }, + "UrlResponse": { + "type": "object", + "properties": { + "url": { + "type": "string" + } + }, + "required": [ + "url" + ] + }, + "CheckoutSessionResult": { + "type": "object", + "properties": { + "sessionId": { + "type": "string" + }, + "url": { + "type": "string" + } + }, + "required": [ + "sessionId", + "url" + ] + }, + "PreviewLineItem": { + "type": "object", + "properties": { + "description": { + "type": "string" + }, + "amount": { + "type": "number", + "description": "Signed amount in minor units; negative for credit on unused time" + }, + "currency": { + "type": "string" + } + }, + "required": [ + "description", + "amount", + "currency" + ] + }, + "SubscriptionUpdatePreview": { + "type": "object", + "properties": { + "amountDue": { + "type": "number" + }, + "currency": { + "type": "string" + }, + "nextBillingDate": { + "type": "number", + "description": "Unix timestamp in seconds" + }, + "lineItems": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PreviewLineItem" + } + } + }, + "required": [ + "amountDue", + "currency", + "nextBillingDate", + "lineItems" + ] + }, + "RemovedSafeDto": { + "type": "object", + "properties": { + "chainId": { + "type": "string" + }, + "address": { + "type": "string" + } + }, + "required": [ + "chainId", + "address" + ] + }, + "UpdateSubscriptionDto": { + "type": "object", + "properties": { + "planId": { + "type": "string", + "description": "The price id of the plan to move the subscription onto" + }, + "paymentLinkId": { + "type": "string", + "description": "Which offered payment link sells that plan. Only needed to disambiguate when several do" + }, + "removedSafes": { + "description": "Safes to remove from the workspace before the plan changes, so it fits the new plan. Safes the workspace does not hold are ignored", + "type": "array", + "items": { + "$ref": "#/components/schemas/RemovedSafeDto" + } + } + }, + "required": [ + "planId" + ] + }, + "UpdateSubscriptionResult": { + "type": "object", + "properties": { + "subscriptionId": { + "type": "string" + }, + "success": { + "type": "boolean" + } + }, + "required": [ + "subscriptionId", + "success" + ] + }, + "CheckoutSession": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "object": { + "type": "string" + }, + "amountSubtotal": { + "type": "number" + }, + "amountTotal": { + "type": "number" + }, + "cancelUrl": { + "type": "string" + }, + "clientReferenceId": { + "type": "object", + "nullable": true + }, + "created": { + "type": "number" + }, + "currency": { + "type": "string" + }, + "customer": { + "type": "object", + "nullable": true + }, + "expiresAt": { + "type": "number" + }, + "metadata": { + "type": "object" + }, + "mode": { + "type": "string" + }, + "paymentStatus": { + "type": "string" + }, + "status": { + "type": "string" + }, + "successUrl": { + "type": "string" + }, + "url": { + "type": "object", + "nullable": true + }, + "subscription": { + "type": "object", + "nullable": true + }, + "invoice": { + "type": "object", + "nullable": true + } + }, + "required": [ + "id", + "object", + "amountSubtotal", + "amountTotal", + "cancelUrl", + "created", + "currency", + "expiresAt", + "metadata", + "mode", + "paymentStatus", + "status", + "successUrl" + ] + }, + "Position": { + "type": "object", + "properties": { + "balance": { + "type": "string" + }, + "fiatBalance": { + "type": "string" + }, + "fiatConversion": { + "type": "string" + }, + "tokenInfo": { + "oneOf": [ + { + "$ref": "#/components/schemas/NativeToken" + }, + { + "$ref": "#/components/schemas/Erc20Token" + }, + { + "$ref": "#/components/schemas/Erc721Token" + } + ] + }, + "fiatBalance24hChange": { + "type": "string", + "nullable": true + }, + "position_type": { + "type": "string", + "enum": [ + "deposit", + "loan", + "locked", + "staked", + "reward", + "wallet", + "airdrop", + "margin", + "unknown" + ], + "nullable": true + } + }, + "required": [ + "balance", + "fiatBalance", + "fiatConversion", + "tokenInfo", + "fiatBalance24hChange", + "position_type" + ] + }, + "PositionGroup": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "items": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/Position" + } + ] + } + } + }, + "required": [ + "name", + "items" + ] + }, + "ProtocolIcon": { + "type": "object", + "properties": { + "url": { + "type": "string", + "nullable": true + } + }, + "required": [ + "url" + ] + }, + "ProtocolMetadata": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "icon": { + "$ref": "#/components/schemas/ProtocolIcon" + } + }, + "required": [ + "name", + "icon" + ] + }, + "Protocol": { + "type": "object", + "properties": { + "protocol": { + "type": "string" + }, + "protocol_metadata": { + "$ref": "#/components/schemas/ProtocolMetadata" + }, + "fiatTotal": { + "type": "string" + }, + "items": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/PositionGroup" + } + ] + } + } + }, + "required": [ + "protocol", + "protocol_metadata", + "fiatTotal", + "items" + ] + }, + "PortfolioNativeToken": { + "type": "object", + "properties": { + "address": { + "type": "string" + }, + "decimals": { + "type": "number" + }, + "logoUri": { + "type": "string" + }, + "name": { + "type": "string" + }, + "symbol": { + "type": "string" + }, + "type": { + "type": "string", + "enum": [ + "NATIVE_TOKEN" + ] + }, + "chainId": { + "type": "string", + "description": "The chain ID" + }, + "trusted": { + "type": "boolean", + "description": "Whether the token is trusted (spam filter)" + } + }, + "required": [ + "address", + "decimals", + "logoUri", + "name", + "symbol", + "type", + "chainId", + "trusted" + ] + }, + "PortfolioErc20Token": { + "type": "object", + "properties": { + "address": { + "type": "string" + }, + "decimals": { + "type": "number" + }, + "logoUri": { + "type": "string" + }, + "name": { + "type": "string" + }, + "symbol": { + "type": "string" + }, + "type": { + "type": "string", + "enum": [ + "ERC20" + ] + }, + "chainId": { + "type": "string", + "description": "The chain ID" + }, + "trusted": { + "type": "boolean", + "description": "Whether the token is trusted (spam filter)" + } + }, + "required": [ + "address", + "decimals", + "logoUri", + "name", + "symbol", + "type", + "chainId", + "trusted" + ] + }, + "PortfolioErc721Token": { + "type": "object", + "properties": { + "address": { + "type": "string" + }, + "decimals": { + "type": "number" + }, + "logoUri": { + "type": "string" + }, + "name": { + "type": "string" + }, + "symbol": { + "type": "string" + }, + "type": { + "type": "string", + "enum": [ + "ERC721" + ] + }, + "chainId": { + "type": "string", + "description": "The chain ID" + }, + "trusted": { + "type": "boolean", + "description": "Whether the token is trusted (spam filter)" + } + }, + "required": [ + "address", + "decimals", + "logoUri", + "name", + "symbol", + "type", + "chainId", + "trusted" + ] + }, + "TokenBalance": { + "type": "object", + "properties": { + "tokenInfo": { + "description": "Token information", + "oneOf": [ + { + "$ref": "#/components/schemas/PortfolioNativeToken" + }, + { + "$ref": "#/components/schemas/PortfolioErc20Token" + }, + { + "$ref": "#/components/schemas/PortfolioErc721Token" + } + ] + }, + "balance": { + "type": "string", + "description": "Balance in smallest unit as string integer. Use decimals to convert." + }, + "balanceFiat": { + "type": "string", + "description": "Balance in requested fiat currency. Decimal string without exponent notation or thousand separators.", + "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", + "example": "4801.653401839" + }, + "price": { + "type": "string", + "description": "Token price in requested fiat currency. Decimal string without exponent notation or thousand separators.", + "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", + "example": "3890.12" + }, + "priceChangePercentage1d": { + "type": "string", + "description": "Price change as decimal (e.g., \"-0.0431\" for -4.31%). Decimal string without exponent notation.", + "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", + "example": "-0.0431" + } + }, + "required": [ + "tokenInfo", + "balance" + ] + }, + "AppPosition": { + "type": "object", + "properties": { + "key": { + "type": "string", + "description": "Unique position key" + }, + "type": { + "type": "string", + "description": "Position type (e.g., staked, lending, liquidity)" + }, + "name": { + "type": "string", + "description": "Position name" + }, + "groupId": { + "type": "string", + "description": "Group ID for grouping related positions together" + }, + "tokenInfo": { + "description": "Token information", + "oneOf": [ + { + "$ref": "#/components/schemas/PortfolioNativeToken" + }, + { + "$ref": "#/components/schemas/PortfolioErc20Token" + }, + { + "$ref": "#/components/schemas/PortfolioErc721Token" + } + ] + }, + "receiptTokenAddress": { + "type": "string", + "description": "Receipt token address (pool address) representing this position. This is the contract address for the position token (LP token, staking receipt, etc.), not the underlying token." + }, + "balance": { + "type": "string", + "description": "Balance in smallest unit as string integer. Use decimals to convert." + }, + "balanceFiat": { + "type": "string", + "description": "Balance in requested fiat currency. Decimal string without exponent notation or thousand separators.", + "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", + "example": "18638914.125656575" + }, + "priceChangePercentage1d": { + "type": "string", + "description": "Price change as decimal (e.g., \"-0.0431\" for -4.31%). Decimal string without exponent notation.", + "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", + "example": "-0.0431" + } + }, + "required": [ + "key", + "type", + "name", + "tokenInfo", + "balance" + ] + }, + "AppPositionGroup": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Group name (e.g., \"Protocol A Vesting\")" + }, + "items": { + "type": "array", + "description": "Positions in this group", + "items": { + "$ref": "#/components/schemas/AppPosition" + } + } + }, + "required": [ + "name", + "items" + ] + }, + "AppBalanceAppInfo": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Application name" + }, + "logoUrl": { + "type": "string", + "format": "uri", + "description": "Application logo URL (HTTPS)" + }, + "url": { + "type": "string", + "format": "uri", + "description": "Application URL (HTTPS)" + } + }, + "required": [ + "name" + ] + }, + "AppBalance": { + "type": "object", + "properties": { + "appInfo": { + "description": "Application information", + "allOf": [ + { + "$ref": "#/components/schemas/AppBalanceAppInfo" + } + ] + }, + "balanceFiat": { + "type": "string", + "description": "Total balance in fiat currency across all position groups. Decimal string without exponent notation or thousand separators.", + "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", + "example": "18638914.125656575" + }, + "groups": { + "type": "array", + "description": "Position groups in this app, grouped by position name", + "items": { + "$ref": "#/components/schemas/AppPositionGroup" + } + } + }, + "required": [ + "appInfo", + "balanceFiat", + "groups" + ] + }, + "Portfolio": { + "type": "object", + "properties": { + "totalBalanceFiat": { + "type": "string", + "description": "Total balance in fiat currency across all tokens and positions. Decimal string without exponent notation or thousand separators.", + "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", + "example": "954181237.094243" + }, + "totalTokenBalanceFiat": { + "type": "string", + "description": "Total balance in fiat currency for all token holdings. Decimal string without exponent notation or thousand separators.", + "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", + "example": "935542322.9685864" + }, + "totalPositionsBalanceFiat": { + "type": "string", + "description": "Total balance in fiat currency for all app positions. Decimal string without exponent notation or thousand separators.", + "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", + "example": "18638914.125656575" + }, + "tokenBalances": { + "description": "List of token balances", + "type": "array", + "items": { + "$ref": "#/components/schemas/TokenBalance" + } + }, + "positionBalances": { + "description": "List of app balances", + "type": "array", + "items": { + "$ref": "#/components/schemas/AppBalance" + } + } + }, + "required": [ + "totalBalanceFiat", + "totalTokenBalanceFiat", + "totalPositionsBalanceFiat", + "tokenBalances", + "positionBalances" + ] + }, + "PortfolioSummarySnapshot": { + "type": "object", + "properties": { + "fiatTotal": { + "type": "string", + "description": "Total across every chain of this address in this environment (mainnets or testnets). Decimal string." + }, + "fiatTotalByChain": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "description": "Total per chain, keyed by chainId. Adds up to fiatTotal. Decimal strings." + }, + "fiatTotalByType": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "description": "Total per Zerion position type (wallet, deposit, loan, staked, locked, reward, ...) across every chain of this address in this environment. Loans are negative. Adds up to fiatTotal. Decimal strings." + }, + "updatedAt": { + "format": "date-time", + "type": "string", + "description": "When the snapshot was fetched from Zerion." + }, + "expiresAt": { + "format": "date-time", + "type": "string", + "description": "Approximately when the cached snapshot expires: the cache adds jitter to its lifetime, and a transaction or a manual refresh can clear it earlier." + } + }, + "required": [ + "fiatTotal", + "fiatTotalByChain", + "fiatTotalByType", + "updatedAt", + "expiresAt" + ] + }, + "PortfolioSummary": { + "type": "object", + "properties": { + "chainId": { + "type": "string" + }, + "address": { + "type": "string" + }, + "fiatTotal": { + "type": "string", + "description": "Value of this Safe on this chain. Decimal string." + }, + "source": { + "type": "string", + "enum": [ + "zerion", + "tx_service" + ], + "description": "zerion: summed from the Zerion snapshot the Assets page reads. tx_service: the chain is not on Zerion, or the snapshot is unavailable." + }, + "snapshot": { + "nullable": true, + "description": "The Zerion snapshot the value was summed from, null for tx_service.", + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/PortfolioSummarySnapshot" + } + ] + } + }, + "required": [ + "chainId", + "address", + "fiatTotal", + "source", + "snapshot" + ] + }, + "GasPriceOracle": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "oracle" + ] + }, + "gasParameter": { + "type": "string" + }, + "gweiFactor": { + "type": "string" + }, + "uri": { + "type": "string" + } + }, + "required": [ + "type", + "gasParameter", + "gweiFactor", + "uri" + ] + }, + "GasPriceFixed": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "fixed" + ] + }, + "weiValue": { + "type": "string" + } + }, + "required": [ + "type", + "weiValue" + ] + }, + "GasPriceFixedEIP1559": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "fixed1559" + ] + }, + "maxFeePerGas": { + "type": "string" + }, + "maxPriorityFeePerGas": { + "type": "string" + } + }, + "required": [ + "type", + "maxFeePerGas", + "maxPriorityFeePerGas" + ] + }, + "NativeCurrency": { + "type": "object", + "properties": { + "decimals": { + "type": "number" + }, + "logoUri": { + "type": "string" + }, + "name": { + "type": "string" + }, + "symbol": { + "type": "string" + } + }, + "required": [ + "decimals", + "logoUri", + "name", + "symbol" + ] + }, + "BlockExplorerUriTemplate": { + "type": "object", + "properties": { + "address": { + "type": "string" + }, + "api": { + "type": "string" + }, + "txHash": { + "type": "string" + } + }, + "required": [ + "address", + "api", + "txHash" + ] + }, + "BalancesProvider": { + "type": "object", + "properties": { + "chainName": { + "type": "string", + "nullable": true + }, + "enabled": { + "type": "boolean" + } + }, + "required": [ + "chainName", + "enabled" + ] + }, + "RpcUri": { + "type": "object", + "properties": { + "authentication": { + "type": "string", + "enum": [ + "API_KEY_PATH", + "NO_AUTHENTICATION", + "UNKNOWN" + ] + }, + "value": { + "type": "string" + } + }, + "required": [ + "authentication", + "value" + ] + }, + "Theme": { + "type": "object", + "properties": { + "backgroundColor": { + "type": "string" + }, + "textColor": { + "type": "string" + } + }, + "required": [ + "backgroundColor", + "textColor" + ] + }, + "Relayer": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "GTF", + "RELAY_FEE", + "DAILY_LIMIT", + "NO_FEE_CAMPAIGN" + ], + "nullable": true + }, + "safeCreationSponsored": { + "type": "boolean" + }, + "safeTransactionSponsored": { + "type": "boolean", + "deprecated": true, + "description": "Use gasPaymentOptions instead." + }, + "enableTenderlySimulationBeforeRelay": { + "type": "boolean" + }, + "gasPaymentOptions": { + "type": "array", + "description": "Who may pay for a relayed transaction on this chain.", + "items": { + "type": "string", + "enum": [ + "FREE_DAILY_LIMIT", + "SUBSCRIPTION", + "PAY_FROM_SAFE", + "NO_FEE_CAMPAIGN" + ] + } + } + }, + "required": [ + "type", + "safeCreationSponsored", + "safeTransactionSponsored", + "enableTenderlySimulationBeforeRelay", + "gasPaymentOptions" + ] + }, + "Chain": { + "type": "object", + "properties": { + "chainId": { + "type": "string" + }, + "chainName": { + "type": "string" + }, + "description": { + "type": "string" + }, + "chainLogoUri": { + "type": "string", + "nullable": true + }, + "l2": { + "type": "boolean" + }, + "isTestnet": { + "type": "boolean" + }, + "zk": { + "type": "boolean" + }, + "nativeCurrency": { + "$ref": "#/components/schemas/NativeCurrency" + }, + "transactionService": { + "type": "string" + }, + "blockExplorerUriTemplate": { + "$ref": "#/components/schemas/BlockExplorerUriTemplate" + }, + "beaconChainExplorerUriTemplate": { + "type": "object" + }, + "disabledWallets": { + "type": "array", + "items": { + "type": "string" + } + }, + "ensRegistryAddress": { + "type": "string", + "nullable": true + }, + "balancesProvider": { + "$ref": "#/components/schemas/BalancesProvider" + }, + "features": { + "type": "array", + "items": { + "type": "string" + } + }, + "gasPrice": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/GasPriceOracle" + }, + { + "$ref": "#/components/schemas/GasPriceFixed" + }, + { + "$ref": "#/components/schemas/GasPriceFixedEIP1559" + } + ] + } + }, + "publicRpcUri": { + "$ref": "#/components/schemas/RpcUri" + }, + "rpcUri": { + "$ref": "#/components/schemas/RpcUri" + }, + "safeAppsRpcUri": { + "$ref": "#/components/schemas/RpcUri" + }, + "shortName": { + "type": "string" + }, + "theme": { + "$ref": "#/components/schemas/Theme" + }, + "recommendedMasterCopyVersion": { + "type": "string", + "nullable": true + }, + "relayer": { + "nullable": true, + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/Relayer" + } + ] + } + }, + "required": [ + "chainId", + "chainName", + "description", + "l2", + "isTestnet", + "zk", + "nativeCurrency", + "transactionService", + "blockExplorerUriTemplate", + "beaconChainExplorerUriTemplate", + "disabledWallets", + "balancesProvider", + "features", + "gasPrice", + "publicRpcUri", + "rpcUri", + "safeAppsRpcUri", + "shortName", + "theme", + "relayer" + ] + }, + "ChainPage": { + "type": "object", + "properties": { + "count": { + "type": "number", + "nullable": true + }, + "next": { + "type": "string", + "nullable": true + }, + "previous": { + "type": "string", + "nullable": true + }, + "results": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Chain" + } + } + }, + "required": [ + "results" + ] + }, + "AboutChain": { + "type": "object", + "properties": { + "transactionServiceBaseUri": { + "type": "string" + }, + "name": { + "type": "string" + }, + "version": { + "type": "string" + }, + "buildNumber": { + "type": "string" + } + }, + "required": [ + "transactionServiceBaseUri", + "name", + "version", + "buildNumber" + ] + }, + "Backbone": { + "type": "object", + "properties": { + "api_version": { + "type": "string" + }, + "headers": { + "type": "string", + "nullable": true + }, + "host": { + "type": "string" + }, + "name": { + "type": "string" + }, + "secure": { + "type": "boolean" + }, + "settings": { + "type": "object", + "nullable": true + }, + "version": { + "type": "string" + } + }, + "required": [ + "api_version", + "host", + "name", + "secure", + "settings", + "version" + ] + }, + "MasterCopy": { + "type": "object", + "properties": { + "address": { + "type": "string" + }, + "version": { + "type": "string" + } + }, + "required": [ + "address", + "version" ] - } - } - }, - "info": { - "title": "Safe Client Gateway", - "description": "", - "version": "main", - "contact": {} - }, - "tags": [], - "servers": [], - "components": { - "schemas": { - "About": { + }, + "IndexingStatus": { "type": "object", "properties": { - "name": { + "currentBlockNumber": { + "type": "number" + }, + "currentBlockTimestamp": { + "format": "date-time", "type": "string" }, - "version": { - "type": "string", - "nullable": true + "erc20BlockNumber": { + "type": "number" }, - "buildNumber": { - "type": "string", - "nullable": true + "erc20BlockTimestamp": { + "format": "date-time", + "type": "string" + }, + "erc20Synced": { + "type": "boolean" + }, + "masterCopiesBlockNumber": { + "type": "number" + }, + "masterCopiesBlockTimestamp": { + "format": "date-time", + "type": "string" + }, + "masterCopiesSynced": { + "type": "boolean" + }, + "synced": { + "type": "boolean" + }, + "lastSync": { + "type": "number" } }, "required": [ - "name" + "currentBlockNumber", + "currentBlockTimestamp", + "erc20BlockNumber", + "erc20BlockTimestamp", + "erc20Synced", + "masterCopiesBlockNumber", + "masterCopiesBlockTimestamp", + "masterCopiesSynced", + "synced", + "lastSync" ] }, - "UserSession": { + "GasPriceResult": { "type": "object", "properties": { - "id": { - "type": "string" + "LastBlock": { + "type": "string", + "description": "Last block number", + "example": "23467872" }, - "authMethod": { + "SafeGasPrice": { "type": "string", - "enum": [ - "siwe", - "oidc" - ] + "description": "Safe gas price recommendation (Gwei)", + "example": "0.496839934" }, - "signerAddress": { + "ProposeGasPrice": { "type": "string", - "description": "Wallet signer address. Present only for SIWE-authenticated users." + "description": "Proposed gas price (Gwei)", + "example": "0.496840168" }, - "email": { + "FastGasPrice": { "type": "string", - "description": "Verified email address. Present only for OIDC-authenticated users when stored." + "description": "Fast gas price recommendation (Gwei)", + "example": "0.55411917" + }, + "suggestBaseFee": { + "type": "string", + "description": "Base fee of the next pending block (Gwei)", + "example": "0.496839934" + }, + "gasUsedRatio": { + "type": "string", + "description": "Gas used ratio to estimate network congestion", + "example": "0.5,0.6,0.7" } }, "required": [ - "id", - "authMethod" + "LastBlock", + "SafeGasPrice", + "ProposeGasPrice", + "FastGasPrice", + "suggestBaseFee", + "gasUsedRatio" ] }, - "AuthNonce": { + "GasPriceResponse": { "type": "object", "properties": { - "nonce": { - "type": "string" + "status": { + "type": "string", + "description": "Status code (\"1\" = success)", + "example": "1" + }, + "message": { + "type": "string", + "description": "Response message", + "example": "OK" + }, + "result": { + "description": "Gas price data", + "allOf": [ + { + "$ref": "#/components/schemas/GasPriceResult" + } + ] } }, "required": [ - "nonce" + "status", + "message", + "result" ] }, - "SiweDto": { + "Collectible": { "type": "object", "properties": { - "message": { + "address": { "type": "string" }, - "signature": { + "tokenName": { + "type": "string" + }, + "tokenSymbol": { + "type": "string" + }, + "logoUri": { + "type": "string" + }, + "id": { "type": "string" + }, + "uri": { + "type": "string", + "nullable": true + }, + "name": { + "type": "string", + "nullable": true + }, + "description": { + "type": "string", + "nullable": true + }, + "imageUri": { + "type": "string", + "nullable": true + }, + "metadata": { + "type": "object", + "nullable": true } }, "required": [ - "message", - "signature" + "address", + "tokenName", + "tokenSymbol", + "logoUri", + "id" ] }, - "LogoutDto": { + "CollectiblePage": { "type": "object", "properties": { - "redirect_url": { + "count": { + "type": "number", + "nullable": true + }, + "next": { "type": "string", - "description": "Post-logout redirect URL (must be same-origin as pre-configured URL)" + "nullable": true + }, + "previous": { + "type": "string", + "nullable": true + }, + "results": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Collectible" + } } - } + }, + "required": [ + "results" + ] }, - "Authenticator": { + "ActivityMetadata": { "type": "object", "properties": { - "id": { + "name": { + "type": "string" + }, + "description": { + "type": "string" + }, + "maxPoints": { + "type": "number" + } + }, + "required": [ + "name", + "description", + "maxPoints" + ] + }, + "Campaign": { + "type": "object", + "properties": { + "resourceId": { + "type": "string" + }, + "name": { + "type": "string" + }, + "description": { + "type": "string" + }, + "startDate": { + "type": "string" + }, + "endDate": { + "type": "string" + }, + "lastUpdated": { + "type": "string", + "nullable": true + }, + "activitiesMetadata": { + "nullable": true, + "type": "array", + "items": { + "$ref": "#/components/schemas/ActivityMetadata" + } + }, + "rewardValue": { "type": "string", - "description": "Auth0 authentication method identifier (e.g. totp|...)" + "nullable": true }, - "type": { + "rewardText": { "type": "string", - "description": "Authentication method type (e.g. totp)" + "nullable": true }, - "name": { + "iconUrl": { "type": "string", - "description": "User-visible authenticator name" + "nullable": true }, - "createdAt": { + "safeAppUrl": { "type": "string", - "description": "ISO 8601 timestamp of when the method was enrolled" + "nullable": true + }, + "partnerUrl": { + "type": "string", + "nullable": true + }, + "isPromoted": { + "type": "boolean" } }, "required": [ - "id", - "type" + "resourceId", + "name", + "description", + "startDate", + "endDate", + "isPromoted" ] }, - "NativeToken": { + "CampaignPage": { "type": "object", "properties": { - "address": { - "type": "string" - }, - "decimals": { - "type": "number" - }, - "logoUri": { - "type": "string" - }, - "name": { - "type": "string" + "count": { + "type": "number", + "nullable": true }, - "symbol": { - "type": "string" + "next": { + "type": "string", + "nullable": true }, - "type": { + "previous": { "type": "string", - "enum": [ - "NATIVE_TOKEN" - ] + "nullable": true + }, + "results": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Campaign" + } } }, "required": [ - "address", - "decimals", - "logoUri", - "name", - "symbol", - "type" + "results" ] }, - "Erc20Token": { + "CampaignRank": { "type": "object", "properties": { - "address": { + "holder": { "type": "string" }, - "decimals": { + "position": { "type": "number" }, - "logoUri": { - "type": "string" - }, - "name": { - "type": "string" + "boost": { + "type": "number" }, - "symbol": { - "type": "string" + "totalPoints": { + "type": "number" }, - "type": { - "type": "string", - "enum": [ - "ERC20" - ] + "totalBoostedPoints": { + "type": "number" } }, "required": [ - "address", - "decimals", - "logoUri", - "name", - "symbol", - "type" + "holder", + "position", + "boost", + "totalPoints", + "totalBoostedPoints" ] }, - "Erc721Token": { + "CampaignRankPage": { "type": "object", "properties": { - "address": { - "type": "string" - }, - "decimals": { - "type": "number" - }, - "logoUri": { - "type": "string" - }, - "name": { - "type": "string" + "count": { + "type": "number", + "nullable": true }, - "symbol": { - "type": "string" + "next": { + "type": "string", + "nullable": true }, - "type": { + "previous": { "type": "string", - "enum": [ - "ERC721" - ] + "nullable": true + }, + "results": { + "type": "array", + "items": { + "$ref": "#/components/schemas/CampaignRank" + } } }, "required": [ - "address", - "decimals", - "logoUri", - "name", - "symbol", - "type" + "results" ] }, - "Balance": { + "EligibilityRequest": { "type": "object", "properties": { - "balance": { - "type": "string" - }, - "fiatBalance": { + "requestId": { "type": "string" }, - "fiatConversion": { + "sealedData": { "type": "string" - }, - "tokenInfo": { - "oneOf": [ - { - "$ref": "#/components/schemas/NativeToken" - }, - { - "$ref": "#/components/schemas/Erc20Token" - }, - { - "$ref": "#/components/schemas/Erc721Token" - } - ] - }, - "fiatBalance24hChange": { - "type": "string", - "nullable": true } }, "required": [ - "balance", - "fiatBalance", - "fiatConversion", - "tokenInfo" + "requestId", + "sealedData" ] }, - "Balances": { + "Eligibility": { "type": "object", "properties": { - "fiatTotal": { + "requestId": { "type": "string" }, - "items": { - "type": "array", - "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/Balance" - } - ] - } + "isAllowed": { + "type": "boolean" + }, + "isVpn": { + "type": "boolean" } }, "required": [ - "fiatTotal", - "items" + "requestId", + "isAllowed", + "isVpn" ] }, - "SubscriptionPlan": { + "LockingRank": { "type": "object", "properties": { - "id": { + "holder": { "type": "string" }, - "name": { - "type": "string", - "nullable": true - }, - "description": { - "type": "string", - "nullable": true - }, - "currentPrice": { + "position": { "type": "number" }, - "originalPrice": { - "type": "number", - "nullable": true - }, - "paymentMethod": { - "type": "string", - "enum": [ - "fiat" - ] - }, - "currency": { - "type": "string", - "enum": [ - "usd", - "eur" - ] + "lockedAmount": { + "type": "string" }, - "features": { - "type": "array", - "items": { - "type": "string" - } + "unlockedAmount": { + "type": "string" }, - "billingCycle": { - "type": "string", - "enum": [ - "month", - "year" - ], + "withdrawnAmount": { + "type": "string" + } + }, + "required": [ + "holder", + "position", + "lockedAmount", + "unlockedAmount", + "withdrawnAmount" + ] + }, + "LockingRankPage": { + "type": "object", + "properties": { + "count": { + "type": "number", "nullable": true }, - "type": { + "next": { "type": "string", - "enum": [ - "standard", - "premium", - "enterprise" - ] + "nullable": true }, - "product": { + "previous": { "type": "string", "nullable": true + }, + "results": { + "type": "array", + "items": { + "$ref": "#/components/schemas/LockingRank" + } } }, "required": [ - "id", - "currentPrice", - "originalPrice", - "paymentMethod", - "currency", - "features", - "type", - "product" + "results" ] }, - "Subscription": { + "LockEventItem": { "type": "object", "properties": { - "id": { + "eventType": { + "type": "string", + "enum": [ + "LOCKED" + ] + }, + "executionDate": { "type": "string" }, - "customerId": { + "transactionHash": { "type": "string" }, - "upstreamCustomerId": { + "holder": { "type": "string" }, - "plan": { - "$ref": "#/components/schemas/SubscriptionPlan" + "amount": { + "type": "string" }, - "status": { + "logIndex": { + "type": "string" + } + }, + "required": [ + "eventType", + "executionDate", + "transactionHash", + "holder", + "amount", + "logIndex" + ] + }, + "UnlockEventItem": { + "type": "object", + "properties": { + "eventType": { "type": "string", "enum": [ - "active", - "canceled", - "incomplete", - "incomplete_expired", - "past_due", - "paused", - "trialing", - "unpaid" + "UNLOCKED" ] }, - "createdAt": { - "type": "number" - }, - "startAt": { - "type": "number" + "executionDate": { + "type": "string" }, - "cancelledAt": { - "type": "number", - "nullable": true + "transactionHash": { + "type": "string" }, - "cancelAt": { - "type": "number", - "nullable": true + "holder": { + "type": "string" }, - "currentPeriodStart": { - "type": "number", - "nullable": true + "amount": { + "type": "string" }, - "currentPeriodEnd": { - "type": "number", - "nullable": true + "logIndex": { + "type": "string" }, - "metadata": { - "type": "object", - "nullable": true - } - }, - "required": [ - "id", - "customerId", - "upstreamCustomerId", - "plan", - "status", - "createdAt", - "startAt", - "cancelledAt", - "cancelAt" - ] - }, - "MarketingFeature": { - "type": "object", - "properties": { - "name": { + "unlockIndex": { "type": "string" } }, "required": [ - "name" + "eventType", + "executionDate", + "transactionHash", + "holder", + "amount", + "logIndex", + "unlockIndex" ] }, - "Product": { + "WithdrawEventItem": { "type": "object", "properties": { - "id": { + "eventType": { + "type": "string", + "enum": [ + "WITHDRAWN" + ] + }, + "executionDate": { "type": "string" }, - "active": { - "type": "boolean" + "transactionHash": { + "type": "string" }, - "description": { + "holder": { "type": "string" }, - "marketingFeatures": { - "type": "array", - "items": { - "$ref": "#/components/schemas/MarketingFeature" - } + "amount": { + "type": "string" }, - "metadata": { - "type": "object" + "logIndex": { + "type": "string" }, - "name": { + "unlockIndex": { "type": "string" } }, "required": [ - "id", - "active", - "description", - "marketingFeatures", - "metadata", - "name" + "eventType", + "executionDate", + "transactionHash", + "holder", + "amount", + "logIndex", + "unlockIndex" ] }, - "Plan": { + "LockingEventPage": { "type": "object", "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string", - "nullable": true - }, - "description": { - "type": "string", - "nullable": true - }, - "currentPrice": { - "type": "number" - }, - "originalPrice": { + "count": { "type": "number", "nullable": true }, - "paymentMethod": { + "next": { "type": "string", - "enum": [ - "fiat" - ] + "nullable": true }, - "currency": { + "previous": { "type": "string", - "enum": [ - "usd", - "eur" - ] + "nullable": true }, - "features": { + "results": { "type": "array", "items": { - "type": "string" + "oneOf": [ + { + "$ref": "#/components/schemas/LockEventItem" + }, + { + "$ref": "#/components/schemas/UnlockEventItem" + }, + { + "$ref": "#/components/schemas/WithdrawEventItem" + } + ] } - }, - "billingCycle": { - "type": "string", - "enum": [ - "month", - "year" - ], - "nullable": true - }, - "type": { - "type": "string", - "enum": [ - "standard", - "premium", - "enterprise" - ] - }, - "product": { - "$ref": "#/components/schemas/Product" } }, "required": [ - "id", - "currentPrice", - "originalPrice", - "paymentMethod", - "currency", - "features", - "type", - "product" + "results" ] }, - "UrlResponse": { + "Contract": { "type": "object", "properties": { - "url": { + "address": { "type": "string" + }, + "name": { + "type": "string" + }, + "displayName": { + "type": "string" + }, + "logoUri": { + "type": "string" + }, + "contractAbi": { + "type": "object", + "nullable": true + }, + "trustedForDelegateCall": { + "type": "boolean" } }, "required": [ - "url" + "address", + "name", + "displayName", + "logoUri", + "trustedForDelegateCall" ] }, - "PaymentLink": { + "TransactionDataDto": { "type": "object", "properties": { - "id": { - "type": "string" - }, - "url": { - "type": "string" - }, - "active": { - "type": "boolean" - }, - "metadata": { - "type": "object" - }, - "customText": { - "type": "object" - }, - "afterCompletion": { - "type": "object" + "data": { + "type": "string", + "description": "Hexadecimal value" }, - "lineItems": { - "type": "array", - "items": { - "type": "object" - } + "to": { + "type": "string", + "description": "The target Ethereum address" } }, "required": [ - "id", - "url", - "active", - "metadata" + "data" ] }, - "CheckoutSessionResult": { + "Operation": { + "type": "number", + "enum": [ + 0, + 1 + ], + "description": "Operation type: 0 for CALL, 1 for DELEGATE" + }, + "BaseDataDecoded": { "type": "object", "properties": { - "sessionId": { + "method": { "type": "string" }, - "url": { - "type": "string" + "parameters": { + "type": "array", + "items": { + "$ref": "#/components/schemas/DataDecodedParameter" + } } }, "required": [ - "sessionId", - "url" + "method" ] }, - "CheckoutSession": { + "MultiSend": { "type": "object", "properties": { - "id": { - "type": "string" - }, - "object": { - "type": "string" - }, - "amountSubtotal": { - "type": "number" - }, - "amountTotal": { - "type": "number" - }, - "cancelUrl": { - "type": "string" - }, - "clientReferenceId": { - "type": "object", - "nullable": true - }, - "created": { - "type": "number" - }, - "currency": { - "type": "string" - }, - "customer": { - "type": "object", - "nullable": true - }, - "expiresAt": { - "type": "number" - }, - "metadata": { - "type": "object" - }, - "mode": { - "type": "string" + "operation": { + "description": "Operation type: 0 for CALL, 1 for DELEGATE", + "allOf": [ + { + "$ref": "#/components/schemas/Operation" + } + ] }, - "paymentStatus": { + "value": { "type": "string" }, - "status": { - "type": "string" + "dataDecoded": { + "$ref": "#/components/schemas/BaseDataDecoded" }, - "successUrl": { + "to": { "type": "string" }, - "url": { - "type": "object", - "nullable": true - }, - "subscription": { - "type": "object", - "nullable": true - }, - "invoice": { - "type": "object", - "nullable": true + "data": { + "type": "string", + "nullable": true, + "description": "Hexadecimal encoded data", + "pattern": "^0x[0-9a-fA-F]*$" } }, "required": [ - "id", - "object", - "amountSubtotal", - "amountTotal", - "cancelUrl", - "created", - "currency", - "expiresAt", - "metadata", - "mode", - "paymentStatus", - "status", - "successUrl" + "operation", + "value", + "to", + "data" ] }, - "Position": { + "DataDecodedParameter": { "type": "object", "properties": { - "balance": { + "name": { "type": "string" }, - "fiatBalance": { + "type": { "type": "string" }, - "fiatConversion": { - "type": "string" + "value": { + "description": "Parameter value - typically a string, but may be an array of strings for array types (e.g., address[], uint256[])", + "oneOf": [ + { + "type": "string" + }, + { + "type": "array", + "items": { + "type": "string" + } + } + ] }, - "tokenInfo": { + "valueDecoded": { "oneOf": [ { - "$ref": "#/components/schemas/NativeToken" + "$ref": "#/components/schemas/BaseDataDecoded" }, { - "$ref": "#/components/schemas/Erc20Token" + "type": "array", + "items": { + "$ref": "#/components/schemas/MultiSend" + } }, { - "$ref": "#/components/schemas/Erc721Token" + "type": "null" } ] - }, - "fiatBalance24hChange": { - "type": "string", - "nullable": true - }, - "position_type": { - "type": "string", - "enum": [ - "deposit", - "loan", - "locked", - "staked", - "reward", - "wallet", - "airdrop", - "margin", - "unknown" - ], - "nullable": true } }, "required": [ - "balance", - "fiatBalance", - "fiatConversion", - "tokenInfo", - "fiatBalance24hChange", - "position_type" + "name", + "type", + "value" ] }, - "PositionGroup": { + "DataDecoded": { "type": "object", "properties": { - "name": { + "method": { "type": "string" }, - "items": { + "parameters": { + "nullable": true, "type": "array", "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/Position" - } - ] + "$ref": "#/components/schemas/DataDecodedParameter" } - } - }, - "required": [ - "name", - "items" - ] - }, - "ProtocolIcon": { - "type": "object", - "properties": { - "url": { + }, + "accuracy": { "type": "string", - "nullable": true + "enum": [ + "FULL_MATCH", + "PARTIAL_MATCH", + "ONLY_FUNCTION_MATCH", + "NO_MATCH", + "UNKNOWN" + ], + "default": "UNKNOWN" } }, "required": [ - "url" + "method" ] }, - "ProtocolMetadata": { + "AddRecoveryModuleDto": { "type": "object", "properties": { - "name": { + "moduleAddress": { "type": "string" - }, - "icon": { - "$ref": "#/components/schemas/ProtocolIcon" } }, "required": [ - "name", - "icon" + "moduleAddress" ] }, - "Protocol": { + "GetEstimationDto": { "type": "object", "properties": { - "protocol": { + "to": { "type": "string" }, - "protocol_metadata": { - "$ref": "#/components/schemas/ProtocolMetadata" - }, - "fiatTotal": { + "value": { "type": "string" }, - "items": { - "type": "array", - "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/PositionGroup" - } - ] - } + "data": { + "type": "string", + "nullable": true + }, + "operation": { + "description": "Operation type: 0 for CALL, 1 for DELEGATE", + "allOf": [ + { + "$ref": "#/components/schemas/Operation" + } + ] } }, "required": [ - "protocol", - "protocol_metadata", - "fiatTotal", - "items" + "to", + "value", + "operation" ] }, - "PortfolioNativeToken": { + "EstimationResponse": { "type": "object", "properties": { - "address": { - "type": "string" - }, - "decimals": { + "currentNonce": { "type": "number" }, - "logoUri": { - "type": "string" - }, - "name": { - "type": "string" + "recommendedNonce": { + "type": "number" }, - "symbol": { + "safeTxGas": { "type": "string" - }, - "type": { - "type": "string", - "enum": [ - "NATIVE_TOKEN" - ] - }, - "chainId": { - "type": "string", - "description": "The chain ID" - }, - "trusted": { - "type": "boolean", - "description": "Whether the token is trusted (spam filter)" } }, "required": [ - "address", - "decimals", - "logoUri", - "name", - "symbol", - "type", - "chainId", - "trusted" + "currentNonce", + "recommendedNonce", + "safeTxGas" ] }, - "PortfolioErc20Token": { + "GasToken": { "type": "object", "properties": { "address": { - "type": "string" - }, - "decimals": { - "type": "number" - }, - "logoUri": { - "type": "string" - }, - "name": { - "type": "string" - }, - "symbol": { - "type": "string" - }, - "type": { "type": "string", - "enum": [ - "ERC20" - ] + "description": "Gas token contract address", + "example": "0x0000000000000000000000000000000000000000" }, - "chainId": { + "symbol": { "type": "string", - "description": "The chain ID" - }, - "trusted": { - "type": "boolean", - "description": "Whether the token is trusted (spam filter)" + "description": "The token's ticker symbol", + "example": "USDC" } }, "required": [ "address", - "decimals", - "logoUri", - "name", - "symbol", - "type", - "chainId", - "trusted" + "symbol" ] }, - "PortfolioErc721Token": { + "GasTokenPage": { "type": "object", "properties": { - "address": { - "type": "string" - }, - "decimals": { - "type": "number" - }, - "logoUri": { - "type": "string" - }, - "name": { - "type": "string" - }, - "symbol": { - "type": "string" + "count": { + "type": "number", + "nullable": true }, - "type": { + "next": { "type": "string", - "enum": [ - "ERC721" - ] + "nullable": true }, - "chainId": { + "previous": { "type": "string", - "description": "The chain ID" + "nullable": true }, - "trusted": { - "type": "boolean", - "description": "Whether the token is trusted (spam filter)" + "results": { + "type": "array", + "items": { + "$ref": "#/components/schemas/GasToken" + } } }, "required": [ - "address", - "decimals", - "logoUri", - "name", - "symbol", - "type", - "chainId", - "trusted" + "results" ] }, - "TokenBalance": { + "Origin": { + "type": "string", + "enum": [ + "SAFE_APP", + "WALLET_CONNECT", + "TX_BUILDER", + "NATIVE" + ], + "description": "Transaction origin. Defaults to NATIVE when omitted." + }, + "FeePreviewTransactionDto": { "type": "object", "properties": { - "tokenInfo": { - "description": "Token information", - "oneOf": [ - { - "$ref": "#/components/schemas/PortfolioNativeToken" - }, - { - "$ref": "#/components/schemas/PortfolioErc20Token" - }, + "to": { + "type": "string" + }, + "value": { + "type": "string" + }, + "data": { + "type": "string" + }, + "operation": { + "description": "Operation type: 0 for CALL, 1 for DELEGATE", + "allOf": [ { - "$ref": "#/components/schemas/PortfolioErc721Token" + "$ref": "#/components/schemas/Operation" } ] }, - "balance": { + "gasToken": { "type": "string", - "description": "Balance in smallest unit as string integer. Use decimals to convert." + "description": "Gas token address (0x0...0 for native token)", + "example": "0x0000000000000000000000000000000000000000" }, - "balanceFiat": { - "type": "string", - "description": "Balance in requested fiat currency. Decimal string without exponent notation or thousand separators.", - "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", - "example": "4801.653401839" + "numberSignatures": { + "type": "number", + "description": "Number of signatures required for execution", + "example": 2, + "minimum": 1 }, - "price": { + "nonce": { "type": "string", - "description": "Token price in requested fiat currency. Decimal string without exponent notation or thousand separators.", - "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", - "example": "3890.12" + "description": "Safe nonce the transaction will use (uint256 string)", + "example": "42" }, - "priceChangePercentage1d": { + "origin": { + "description": "Transaction origin. Defaults to NATIVE when omitted.", + "allOf": [ + { + "$ref": "#/components/schemas/Origin" + } + ] + }, + "fiatCode": { "type": "string", - "description": "Price change as decimal (e.g., \"-0.0431\" for -4.31%). Decimal string without exponent notation.", - "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", - "example": "-0.0431" + "description": "Fiat currency code for relay cost conversion (e.g. EUR, GBP). Defaults to USD.", + "example": "EUR" } }, "required": [ - "tokenInfo", - "balance" + "to", + "value", + "data", + "operation", + "gasToken", + "numberSignatures", + "nonce" ] }, - "AppPosition": { + "FeePreviewTxData": { "type": "object", "properties": { - "key": { + "chainId": { "type": "string", - "description": "Unique position key" + "description": "Chain ID", + "example": "1" }, - "type": { + "safeAddress": { "type": "string", - "description": "Position type (e.g., staked, lending, liquidity)" + "description": "Safe address", + "example": "0x..." }, - "name": { + "safeTxGas": { "type": "string", - "description": "Position name" + "description": "Safe transaction gas", + "example": "150000" }, - "groupId": { + "baseGas": { "type": "string", - "description": "Group ID for grouping related positions together" - }, - "tokenInfo": { - "description": "Token information", - "oneOf": [ - { - "$ref": "#/components/schemas/PortfolioNativeToken" - }, - { - "$ref": "#/components/schemas/PortfolioErc20Token" - }, - { - "$ref": "#/components/schemas/PortfolioErc721Token" - } - ] + "description": "Base gas for relay overhead", + "example": "48564" }, - "receiptTokenAddress": { + "gasPrice": { "type": "string", - "description": "Receipt token address (pool address) representing this position. This is the contract address for the position token (LP token, staking receipt, etc.), not the underlying token." + "description": "Gas price per gas unit. Denominated in wei when `gasToken` is the native token (zero address), or in the ERC20 gas token atomic units per gas otherwise", + "example": "195000000000000" }, - "balance": { + "gasToken": { "type": "string", - "description": "Balance in smallest unit as string integer. Use decimals to convert." + "description": "Gas token address", + "example": "0x0000000000000000000000000000000000000000" }, - "balanceFiat": { + "refundReceiver": { "type": "string", - "description": "Balance in requested fiat currency. Decimal string without exponent notation or thousand separators.", - "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", - "example": "18638914.125656575" + "description": "Refund receiver address", + "example": "0x0000000000000000000000000000000000000000" }, - "priceChangePercentage1d": { - "type": "string", - "description": "Price change as decimal (e.g., \"-0.0431\" for -4.31%). Decimal string without exponent notation.", - "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", - "example": "-0.0431" + "numberSignatures": { + "type": "number", + "description": "Number of signatures", + "example": 2 } }, "required": [ - "key", - "type", - "name", - "tokenInfo", - "balance" + "chainId", + "safeAddress", + "safeTxGas", + "baseGas", + "gasPrice", + "gasToken", + "refundReceiver", + "numberSignatures" ] }, - "AppPositionGroup": { + "FeePreviewRelayCost": { "type": "object", "properties": { - "name": { + "fiatCode": { "type": "string", - "description": "Group name (e.g., \"Protocol A Vesting\")" + "description": "Fiat currency code", + "example": "USD" }, - "items": { - "type": "array", - "description": "Positions in this group", - "items": { - "$ref": "#/components/schemas/AppPosition" - } + "fiatValue": { + "type": "string", + "description": "Relay cost as a string", + "example": "0.0025" } }, "required": [ - "name", - "items" + "fiatCode", + "fiatValue" ] }, - "AppBalanceAppInfo": { + "FeePreviewValuationDetail": { "type": "object", "properties": { - "name": { + "tokenAddress": { "type": "string", - "description": "Application name" + "description": "Token contract address (absent for native transfers)" }, - "logoUrl": { + "symbol": { "type": "string", - "format": "uri", - "description": "Application logo URL (HTTPS)" + "description": "Token symbol", + "example": "USDC" }, - "url": { + "amount": { "type": "string", - "format": "uri", - "description": "Application URL (HTTPS)" + "description": "Token amount", + "example": "1000" + }, + "priceUsd": { + "type": "number", + "description": "Token price in USD" + }, + "valueUsd": { + "type": "number", + "description": "Token value in USD" } }, "required": [ - "name" + "symbol", + "amount" ] }, - "AppBalance": { + "FeePreviewFeeBreakdown": { "type": "object", "properties": { - "appInfo": { - "description": "Application information", + "txValueUsd": { + "type": "number", + "description": "Transaction value in USD", + "example": 1000 + }, + "trailingVolumeUsd": { + "type": "number", + "description": "Trailing volume in USD that fed tier selection", + "example": 0 + }, + "tierBps": { + "type": "number", + "description": "Tier fee in basis points", + "example": 5 + }, + "gtfFeeUsd": { + "type": "number", + "description": "GTF fee in USD", + "example": 0.5 + }, + "relayCostUsd": { + "type": "number", + "description": "Relay cost in USD", + "example": 38.22 + }, + "totalUsd": { + "type": "number", + "description": "Total fee in USD", + "example": 38.72 + }, + "numberSignatures": { + "type": "number", + "description": "Number of signatures", + "example": 2 + }, + "valuationDetails": { + "type": "array", + "items": { + "$ref": "#/components/schemas/FeePreviewValuationDetail" + } + } + }, + "required": [ + "txValueUsd", + "trailingVolumeUsd", + "tierBps", + "gtfFeeUsd", + "relayCostUsd", + "totalUsd", + "numberSignatures", + "valuationDetails" + ] + }, + "FeePreviewResponse": { + "type": "object", + "properties": { + "txData": { + "$ref": "#/components/schemas/FeePreviewTxData" + }, + "relayCost": { + "description": "Relay cost. Present when the relay fee flow applies.", "allOf": [ { - "$ref": "#/components/schemas/AppBalanceAppInfo" + "$ref": "#/components/schemas/FeePreviewRelayCost" } ] }, - "balanceFiat": { - "type": "string", - "description": "Total balance in fiat currency across all position groups. Decimal string without exponent notation or thousand separators.", - "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", - "example": "18638914.125656575" + "feeBreakdown": { + "description": "GTF fee breakdown, as returned by the fee-engine service. Present when the GTF fee flow applies.", + "allOf": [ + { + "$ref": "#/components/schemas/FeePreviewFeeBreakdown" + } + ] }, - "groups": { - "type": "array", - "description": "Position groups in this app, grouped by position name", - "items": { - "$ref": "#/components/schemas/AppPositionGroup" - } + "maxFeeCapUsd": { + "type": "number", + "description": "Maximum fee cap in USD (buffered max fee). Present when the GTF fee flow applies." } }, "required": [ - "appInfo", - "balanceFiat", - "groups" + "txData" ] }, - "Portfolio": { + "TypedDataParameter": { "type": "object", "properties": { - "totalBalanceFiat": { - "type": "string", - "description": "Total balance in fiat currency across all tokens and positions. Decimal string without exponent notation or thousand separators.", - "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", - "example": "954181237.094243" + "name": { + "type": "string" }, - "totalTokenBalanceFiat": { - "type": "string", - "description": "Total balance in fiat currency for all token holdings. Decimal string without exponent notation or thousand separators.", - "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", - "example": "935542322.9685864" + "type": { + "type": "string" + } + }, + "required": [ + "name", + "type" + ] + }, + "TypedDataDomain": { + "type": "object", + "properties": { + "chainId": { + "type": "number" }, - "totalPositionsBalanceFiat": { - "type": "string", - "description": "Total balance in fiat currency for all app positions. Decimal string without exponent notation or thousand separators.", - "pattern": "^-?(?:0|[1-9]\\d*)(?:\\.\\d+)?$", - "example": "18638914.125656575" + "name": { + "type": "string" }, - "tokenBalances": { - "description": "List of token balances", - "type": "array", - "items": { - "$ref": "#/components/schemas/TokenBalance" - } + "salt": { + "type": "string" }, - "positionBalances": { - "description": "List of app balances", - "type": "array", - "items": { - "$ref": "#/components/schemas/AppBalance" - } + "verifyingContract": { + "type": "string" + }, + "version": { + "type": "string" + }, + "safe": { + "type": "string" } - }, - "required": [ - "totalBalanceFiat", - "totalTokenBalanceFiat", - "totalPositionsBalanceFiat", - "tokenBalances", - "positionBalances" - ] + } }, - "GasPriceOracle": { + "TypedData": { "type": "object", "properties": { - "type": { - "type": "string", - "enum": [ - "oracle" - ] + "domain": { + "$ref": "#/components/schemas/TypedDataDomain" }, - "gasParameter": { + "primaryType": { "type": "string" }, - "gweiFactor": { - "type": "string" + "types": { + "type": "object", + "additionalProperties": { + "items": { + "$ref": "#/components/schemas/TypedDataParameter" + }, + "type": "array" + } }, - "uri": { - "type": "string" + "message": { + "type": "object", + "additionalProperties": true } }, "required": [ - "type", - "gasParameter", - "gweiFactor", - "uri" + "domain", + "primaryType", + "types", + "message" ] }, - "GasPriceFixed": { + "AddressInfo": { "type": "object", "properties": { - "type": { + "value": { + "type": "string" + }, + "name": { "type": "string", - "enum": [ - "fixed" - ] + "nullable": true }, - "weiValue": { - "type": "string" + "logoUri": { + "type": "string", + "nullable": true } }, "required": [ - "type", - "weiValue" + "value" ] }, - "GasPriceFixedEIP1559": { + "MessageConfirmation": { "type": "object", "properties": { - "type": { - "type": "string", - "enum": [ - "fixed1559" - ] - }, - "maxFeePerGas": { - "type": "string" + "owner": { + "$ref": "#/components/schemas/AddressInfo" }, - "maxPriorityFeePerGas": { + "signature": { "type": "string" } }, "required": [ - "type", - "maxFeePerGas", - "maxPriorityFeePerGas" + "owner", + "signature" ] }, - "NativeCurrency": { + "SafeAppInfo": { "type": "object", "properties": { - "decimals": { + "id": { "type": "number" }, - "logoUri": { - "type": "string" - }, "name": { "type": "string" }, - "symbol": { + "url": { "type": "string" + }, + "logoUri": { + "type": "string", + "nullable": true } }, "required": [ - "decimals", - "logoUri", + "id", "name", - "symbol" + "url" ] }, - "BlockExplorerUriTemplate": { + "Message": { "type": "object", "properties": { - "address": { + "messageHash": { "type": "string" }, - "api": { - "type": "string" + "status": { + "type": "string", + "enum": [ + "NEEDS_CONFIRMATION", + "CONFIRMED" + ] }, - "txHash": { - "type": "string" + "logoUri": { + "type": "string", + "nullable": true, + "deprecated": true + }, + "name": { + "type": "string", + "nullable": true, + "deprecated": true + }, + "message": { + "oneOf": [ + { + "type": "string" + }, + { + "$ref": "#/components/schemas/TypedData" + } + ] + }, + "creationTimestamp": { + "type": "number" + }, + "modifiedTimestamp": { + "type": "number" + }, + "confirmationsSubmitted": { + "type": "number" + }, + "confirmationsRequired": { + "type": "number" + }, + "proposedBy": { + "nullable": true, + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/AddressInfo" + } + ] + }, + "confirmations": { + "type": "array", + "items": { + "$ref": "#/components/schemas/MessageConfirmation" + } + }, + "preparedSignature": { + "type": "string", + "nullable": true + }, + "origin": { + "type": "string", + "nullable": true + }, + "safeAppInfo": { + "nullable": true, + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/SafeAppInfo" + } + ] + }, + "safeAppId": { + "type": "number", + "nullable": true, + "deprecated": true } }, "required": [ - "address", - "api", - "txHash" + "messageHash", + "status", + "logoUri", + "name", + "message", + "creationTimestamp", + "modifiedTimestamp", + "confirmationsSubmitted", + "confirmationsRequired", + "proposedBy", + "confirmations", + "preparedSignature", + "origin", + "safeAppInfo", + "safeAppId" ] }, - "BalancesProvider": { + "MessageItem": { "type": "object", "properties": { - "chainName": { + "messageHash": { + "type": "string" + }, + "status": { + "type": "string", + "enum": [ + "NEEDS_CONFIRMATION", + "CONFIRMED" + ] + }, + "logoUri": { + "type": "string", + "nullable": true, + "deprecated": true + }, + "name": { + "type": "string", + "nullable": true, + "deprecated": true + }, + "message": { + "oneOf": [ + { + "type": "string" + }, + { + "$ref": "#/components/schemas/TypedData" + } + ] + }, + "creationTimestamp": { + "type": "number" + }, + "modifiedTimestamp": { + "type": "number" + }, + "confirmationsSubmitted": { + "type": "number" + }, + "confirmationsRequired": { + "type": "number" + }, + "proposedBy": { + "nullable": true, + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/AddressInfo" + } + ] + }, + "confirmations": { + "type": "array", + "items": { + "$ref": "#/components/schemas/MessageConfirmation" + } + }, + "preparedSignature": { "type": "string", "nullable": true }, - "enabled": { - "type": "boolean" - } - }, - "required": [ - "chainName", - "enabled" - ] - }, - "RpcUri": { - "type": "object", - "properties": { - "authentication": { + "origin": { "type": "string", - "enum": [ - "API_KEY_PATH", - "NO_AUTHENTICATION", - "UNKNOWN" + "nullable": true + }, + "safeAppInfo": { + "nullable": true, + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/SafeAppInfo" + } ] }, - "value": { - "type": "string" - } - }, - "required": [ - "authentication", - "value" - ] - }, - "Theme": { - "type": "object", - "properties": { - "backgroundColor": { - "type": "string" + "safeAppId": { + "type": "number", + "nullable": true, + "deprecated": true }, - "textColor": { - "type": "string" + "type": { + "type": "string", + "enum": [ + "MESSAGE" + ] } }, "required": [ - "backgroundColor", - "textColor" + "messageHash", + "status", + "logoUri", + "name", + "message", + "creationTimestamp", + "modifiedTimestamp", + "confirmationsSubmitted", + "confirmationsRequired", + "proposedBy", + "confirmations", + "preparedSignature", + "origin", + "safeAppInfo", + "safeAppId", + "type" ] }, - "Relayer": { + "DateLabel": { "type": "object", "properties": { "type": { "type": "string", "enum": [ - "GTF", - "RELAY_FEE", - "DAILY_LIMIT", - "NO_FEE_CAMPAIGN" - ], - "nullable": true - }, - "safeCreationSponsored": { - "type": "boolean" - }, - "safeTransactionSponsored": { - "type": "boolean" + "DATE_LABEL" + ] }, - "enableTenderlySimulationBeforeRelay": { - "type": "boolean" + "timestamp": { + "type": "number" } }, "required": [ "type", - "safeCreationSponsored", - "safeTransactionSponsored", - "enableTenderlySimulationBeforeRelay" + "timestamp" ] }, - "Chain": { + "MessagePage": { "type": "object", "properties": { - "chainId": { - "type": "string" - }, - "chainName": { - "type": "string" - }, - "description": { - "type": "string" + "count": { + "type": "number", + "nullable": true }, - "chainLogoUri": { + "next": { "type": "string", "nullable": true }, - "l2": { - "type": "boolean" - }, - "isTestnet": { - "type": "boolean" - }, - "zk": { - "type": "boolean" - }, - "nativeCurrency": { - "$ref": "#/components/schemas/NativeCurrency" - }, - "transactionService": { - "type": "string" - }, - "blockExplorerUriTemplate": { - "$ref": "#/components/schemas/BlockExplorerUriTemplate" - }, - "beaconChainExplorerUriTemplate": { - "type": "object" - }, - "disabledWallets": { - "type": "array", - "items": { - "type": "string" - } - }, - "ensRegistryAddress": { + "previous": { "type": "string", "nullable": true }, - "balancesProvider": { - "$ref": "#/components/schemas/BalancesProvider" - }, - "features": { - "type": "array", - "items": { - "type": "string" - } - }, - "gasPrice": { + "results": { "type": "array", "items": { "oneOf": [ { - "$ref": "#/components/schemas/GasPriceOracle" - }, - { - "$ref": "#/components/schemas/GasPriceFixed" + "$ref": "#/components/schemas/MessageItem" }, { - "$ref": "#/components/schemas/GasPriceFixedEIP1559" + "$ref": "#/components/schemas/DateLabel" } ] } + } + }, + "required": [ + "results" + ] + }, + "DeclaredAttributionDto": { + "type": "object", + "properties": { + "channel": { + "type": "string", + "nullable": true, + "description": "Where the user started the request. Known values: NATIVE_TRANSFER, NATIVE_BATCH, SAFE_APP, WALLET_CONNECT, WIDGET, DIRECT, MCP, CLI. Truncated to 64 characters." }, - "publicRpcUri": { - "$ref": "#/components/schemas/RpcUri" + "appName": { + "type": "string", + "nullable": true, + "description": "App name. Truncated to 256 characters." }, - "rpcUri": { - "$ref": "#/components/schemas/RpcUri" + "appUrl": { + "type": "string", + "nullable": true, + "description": "App origin and path. Truncated to 2048 characters." }, - "safeAppsRpcUri": { - "$ref": "#/components/schemas/RpcUri" + "appId": { + "type": "number", + "nullable": true, + "description": "ID of a listed Safe App." + } + } + }, + "CreateMessageDto": { + "type": "object", + "properties": { + "message": { + "oneOf": [ + { + "type": "string" + }, + { + "$ref": "#/components/schemas/TypedData" + } + ] }, - "shortName": { - "type": "string" + "safeAppId": { + "type": "number", + "nullable": true, + "deprecated": true }, - "theme": { - "$ref": "#/components/schemas/Theme" + "signature": { + "type": "string" }, - "recommendedMasterCopyVersion": { + "origin": { "type": "string", "nullable": true }, - "relayer": { + "declared": { "nullable": true, + "description": "Where the request came from, as reported by the client.", "type": "object", "allOf": [ { - "$ref": "#/components/schemas/Relayer" + "$ref": "#/components/schemas/DeclaredAttributionDto" } ] } }, "required": [ - "chainId", - "chainName", - "description", - "l2", - "isTestnet", - "zk", - "nativeCurrency", - "transactionService", - "blockExplorerUriTemplate", - "beaconChainExplorerUriTemplate", - "disabledWallets", - "balancesProvider", - "features", - "gasPrice", - "publicRpcUri", - "rpcUri", - "safeAppsRpcUri", - "shortName", - "theme", - "relayer" + "message", + "signature" ] }, - "ChainPage": { + "UpdateMessageSignatureDto": { "type": "object", "properties": { - "count": { - "type": "number", - "nullable": true - }, - "next": { - "type": "string", - "nullable": true - }, - "previous": { - "type": "string", - "nullable": true + "signature": { + "type": "string" + } + }, + "required": [ + "signature" + ] + }, + "UserWallet": { + "type": "object", + "properties": { + "id": { + "type": "number" }, - "results": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Chain" - } + "address": { + "type": "string" } }, "required": [ - "results" + "id", + "address" ] }, - "AboutChain": { + "UserWithWallets": { "type": "object", "properties": { - "transactionServiceBaseUri": { - "type": "string" - }, - "name": { - "type": "string" + "id": { + "type": "number" }, - "version": { - "type": "string" + "status": { + "type": "number", + "enum": [ + 0, + 1 + ] }, - "buildNumber": { - "type": "string" + "wallets": { + "type": "array", + "items": { + "$ref": "#/components/schemas/UserWallet" + } } }, "required": [ - "transactionServiceBaseUri", - "name", - "version", - "buildNumber" + "id", + "status", + "wallets" ] }, - "Backbone": { + "CreatedUserWithWallet": { "type": "object", "properties": { - "api_version": { - "type": "string" - }, - "headers": { - "type": "string", - "nullable": true - }, - "host": { - "type": "string" - }, - "name": { - "type": "string" - }, - "secure": { - "type": "boolean" - }, - "settings": { - "type": "object", - "nullable": true - }, - "version": { - "type": "string" + "id": { + "type": "number" } }, "required": [ - "api_version", - "host", - "name", - "secure", - "settings", - "version" + "id" ] }, - "MasterCopy": { + "WalletAddedToUser": { "type": "object", "properties": { - "address": { - "type": "string" - }, - "version": { - "type": "string" + "id": { + "type": "number" } }, "required": [ - "address", - "version" + "id" ] }, - "IndexingStatus": { + "SpaceAddressBookItemDto": { "type": "object", "properties": { - "currentBlockNumber": { - "type": "number" + "name": { + "type": "string" }, - "currentBlockTimestamp": { - "format": "date-time", + "address": { "type": "string" }, - "erc20BlockNumber": { - "type": "number" + "chainIds": { + "type": "array", + "items": { + "type": "string" + } }, - "erc20BlockTimestamp": { - "format": "date-time", - "type": "string" + "tagIds": { + "description": "IDs of the workspace tags assigned to the contact", + "type": "array", + "items": { + "type": "number" + } }, - "erc20Synced": { - "type": "boolean" + "createdBy": { + "type": "string", + "description": "Email or wallet address of the creator, \"Unknown user\" if the user has no display identity, or \"Deleted user\"" }, - "masterCopiesBlockNumber": { - "type": "number" + "createdByUserId": { + "type": "number", + "description": "User ID of the creator" }, - "masterCopiesBlockTimestamp": { - "format": "date-time", - "type": "string" + "lastUpdatedBy": { + "type": "string", + "description": "Email or wallet address of the last editor, \"Unknown user\" if the user has no display identity, or \"Deleted user\"" }, - "masterCopiesSynced": { - "type": "boolean" + "lastUpdatedByUserId": { + "type": "number", + "description": "User ID of the last editor" }, - "synced": { - "type": "boolean" + "createdAt": { + "format": "date-time", + "type": "string" }, - "lastSync": { - "type": "number" + "updatedAt": { + "format": "date-time", + "type": "string" } }, "required": [ - "currentBlockNumber", - "currentBlockTimestamp", - "erc20BlockNumber", - "erc20BlockTimestamp", - "erc20Synced", - "masterCopiesBlockNumber", - "masterCopiesBlockTimestamp", - "masterCopiesSynced", - "synced", - "lastSync" + "name", + "address", + "chainIds", + "tagIds", + "createdBy", + "createdByUserId", + "lastUpdatedBy", + "lastUpdatedByUserId", + "createdAt", + "updatedAt" ] }, - "GasPriceResult": { + "SpaceAddressBookTagDto": { "type": "object", "properties": { - "LastBlock": { - "type": "string", - "description": "Last block number", - "example": "23467872" + "id": { + "type": "number" }, - "SafeGasPrice": { - "type": "string", - "description": "Safe gas price recommendation (Gwei)", - "example": "0.496839934" + "name": { + "type": "string" }, - "ProposeGasPrice": { + "color": { "type": "string", - "description": "Proposed gas price (Gwei)", - "example": "0.496840168" + "enum": [ + "slate", + "clay", + "rose", + "lilac", + "iris", + "cobalt", + "sky", + "lagoon" + ] }, - "FastGasPrice": { + "contactCount": { + "type": "number", + "description": "Number of contacts that have this tag" + } + }, + "required": [ + "id", + "name", + "color", + "contactCount" + ] + }, + "SpaceAddressBookDto": { + "type": "object", + "properties": { + "spaceUuid": { "type": "string", - "description": "Fast gas price recommendation (Gwei)", - "example": "0.55411917" + "description": "Space UUID" }, - "suggestBaseFee": { - "type": "string", - "description": "Base fee of the next pending block (Gwei)", - "example": "0.496839934" + "data": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SpaceAddressBookItemDto" + } }, - "gasUsedRatio": { - "type": "string", - "description": "Gas used ratio to estimate network congestion", - "example": "0.5,0.6,0.7" + "tags": { + "description": "All tags defined in the workspace address book", + "type": "array", + "items": { + "$ref": "#/components/schemas/SpaceAddressBookTagDto" + } } }, "required": [ - "LastBlock", - "SafeGasPrice", - "ProposeGasPrice", - "FastGasPrice", - "suggestBaseFee", - "gasUsedRatio" + "spaceUuid", + "data", + "tags" ] }, - "GasPriceResponse": { + "UpsertAddressBookItem": { "type": "object", "properties": { - "status": { - "type": "string", - "description": "Status code (\"1\" = success)", - "example": "1" + "name": { + "type": "string" }, - "message": { - "type": "string", - "description": "Response message", - "example": "OK" + "address": { + "type": "string" }, - "result": { - "description": "Gas price data", - "allOf": [ - { - "$ref": "#/components/schemas/GasPriceResult" - } - ] + "chainIds": { + "type": "array", + "items": { + "type": "string" + } + }, + "tags": { + "maxItems": 3, + "description": "Tag names of the contact (replaces the current tags when provided; omit to leave them unchanged)", + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "name", + "address", + "chainIds" + ] + }, + "UpsertAddressBookItemsDto": { + "type": "object", + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/UpsertAddressBookItem" + } } }, "required": [ - "status", - "message", - "result" + "items" ] }, - "Collectible": { + "SetContactTagsItem": { "type": "object", "properties": { "address": { "type": "string" }, - "tokenName": { - "type": "string" - }, - "tokenSymbol": { - "type": "string" - }, - "logoUri": { - "type": "string" - }, - "id": { - "type": "string" - }, - "uri": { - "type": "string", - "nullable": true - }, - "name": { - "type": "string", - "nullable": true - }, - "description": { - "type": "string", - "nullable": true - }, - "imageUri": { - "type": "string", - "nullable": true - }, - "metadata": { - "type": "object", - "nullable": true + "tags": { + "maxItems": 3, + "description": "The full set of tag names for the contact. 'Workspace Safe' and 'Signer' aren't allowed, in any case", + "type": "array", + "items": { + "type": "string" + } } }, "required": [ "address", - "tokenName", - "tokenSymbol", - "logoUri", - "id" + "tags" ] }, - "CollectiblePage": { + "SetContactTagsDto": { "type": "object", "properties": { - "count": { - "type": "number", - "nullable": true - }, - "next": { - "type": "string", - "nullable": true - }, - "previous": { - "type": "string", - "nullable": true - }, - "results": { + "items": { "type": "array", "items": { - "$ref": "#/components/schemas/Collectible" - } + "$ref": "#/components/schemas/SetContactTagsItem" + }, + "minItems": 1, + "description": "At most as many entries as the address book can hold, each address at most once" } }, "required": [ - "results" + "items" ] }, - "ActivityMetadata": { + "CreateTagDto": { "type": "object", "properties": { "name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "maxPoints": { - "type": "number" + "type": "string", + "maxLength": 32, + "description": "'Workspace Safe' and 'Signer' aren't allowed, in any case" } }, "required": [ - "name", - "description", - "maxPoints" + "name" ] }, - "Campaign": { + "RenameTagDto": { "type": "object", "properties": { - "resourceId": { - "type": "string" - }, "name": { - "type": "string" - }, - "description": { - "type": "string" + "type": "string", + "maxLength": 32, + "description": "'Workspace Safe' and 'Signer' aren't allowed, in any case" + } + }, + "required": [ + "name" + ] + }, + "AddressBookRequestItemDto": { + "type": "object", + "properties": { + "id": { + "type": "number" }, - "startDate": { + "name": { "type": "string" }, - "endDate": { + "address": { "type": "string" }, - "lastUpdated": { - "type": "string", - "nullable": true - }, - "activitiesMetadata": { - "nullable": true, + "chainIds": { "type": "array", "items": { - "$ref": "#/components/schemas/ActivityMetadata" + "type": "string" } }, - "rewardValue": { + "requestedBy": { "type": "string", - "nullable": true + "description": "Email or wallet address of the requester, \"Unknown user\" if the user has no display identity, or \"Deleted user\"" }, - "rewardText": { - "type": "string", - "nullable": true + "requestedByUserId": { + "type": "number", + "description": "User ID of the requester" }, - "iconUrl": { + "reviewedBy": { "type": "string", - "nullable": true + "nullable": true, + "description": "Email or wallet address of the reviewing admin, \"Unknown user\", \"Deleted user\", or null when still PENDING" }, - "safeAppUrl": { - "type": "string", - "nullable": true + "reviewedByUserId": { + "type": "number", + "nullable": true, + "description": "User ID of the reviewing admin, null when still PENDING" }, - "partnerUrl": { + "status": { "type": "string", - "nullable": true + "enum": [ + "PENDING", + "APPROVED", + "REJECTED" + ] }, - "isPromoted": { - "type": "boolean" + "createdAt": { + "format": "date-time", + "type": "string" + }, + "updatedAt": { + "format": "date-time", + "type": "string" } }, "required": [ - "resourceId", + "id", "name", - "description", - "startDate", - "endDate", - "isPromoted" + "address", + "chainIds", + "requestedBy", + "requestedByUserId", + "reviewedBy", + "reviewedByUserId", + "status", + "createdAt", + "updatedAt" ] }, - "CampaignPage": { + "AddressBookRequestsDto": { "type": "object", "properties": { - "count": { - "type": "number", - "nullable": true - }, - "next": { - "type": "string", - "nullable": true - }, - "previous": { + "spaceUuid": { "type": "string", - "nullable": true + "description": "Space UUID" }, - "results": { + "data": { "type": "array", "items": { - "$ref": "#/components/schemas/Campaign" + "$ref": "#/components/schemas/AddressBookRequestItemDto" } } }, "required": [ - "results" - ] - }, - "CampaignRank": { - "type": "object", - "properties": { - "holder": { - "type": "string" - }, - "position": { - "type": "number" - }, - "boost": { - "type": "number" - }, - "totalPoints": { - "type": "number" - }, - "totalBoostedPoints": { - "type": "number" - } - }, - "required": [ - "holder", - "position", - "boost", - "totalPoints", - "totalBoostedPoints" + "spaceUuid", + "data" ] }, - "CampaignRankPage": { + "CreateAddressBookRequestDto": { "type": "object", "properties": { - "count": { - "type": "number", - "nullable": true - }, - "next": { + "name": { "type": "string", - "nullable": true + "maxLength": 50, + "description": "Name of the proposed contact" }, - "previous": { + "address": { "type": "string", - "nullable": true + "description": "Address of the contact to propose for the space address book" }, - "results": { + "chainIds": { + "description": "Chain ids the contact applies to (at least one, duplicates are removed)", "type": "array", "items": { - "$ref": "#/components/schemas/CampaignRank" + "type": "string" } } }, "required": [ - "results" + "name", + "address", + "chainIds" ] }, - "EligibilityRequest": { + "CreateSpaceDto": { "type": "object", "properties": { - "requestId": { - "type": "string" - }, - "sealedData": { + "name": { "type": "string" } }, "required": [ - "requestId", - "sealedData" + "name" ] }, - "Eligibility": { + "CreateSpaceResponse": { "type": "object", "properties": { - "requestId": { + "name": { "type": "string" }, - "isAllowed": { - "type": "boolean" - }, - "isVpn": { - "type": "boolean" + "uuid": { + "type": "string", + "description": "Space UUID" } }, "required": [ - "requestId", - "isAllowed", - "isVpn" + "name", + "uuid" ] }, - "LockingRank": { + "WalletInviteUserDto": { "type": "object", "properties": { - "holder": { - "type": "string" - }, - "position": { - "type": "number" + "type": { + "type": "string", + "enum": [ + "wallet" + ] }, - "lockedAmount": { + "address": { "type": "string" }, - "unlockedAmount": { - "type": "string" + "role": { + "type": "string", + "enum": [ + "ADMIN", + "MEMBER" + ] }, - "withdrawnAmount": { - "type": "string" + "name": { + "type": "string", + "maxLength": 255 } }, "required": [ - "holder", - "position", - "lockedAmount", - "unlockedAmount", - "withdrawnAmount" + "type", + "address", + "role", + "name" ] }, - "LockingRankPage": { + "EmailInviteUserDto": { "type": "object", "properties": { - "count": { - "type": "number", - "nullable": true + "type": { + "type": "string", + "enum": [ + "email" + ] }, - "next": { + "email": { "type": "string", - "nullable": true + "format": "email", + "maxLength": 255 }, - "previous": { + "role": { "type": "string", - "nullable": true + "enum": [ + "ADMIN", + "MEMBER" + ] }, - "results": { - "type": "array", - "items": { - "$ref": "#/components/schemas/LockingRank" - } + "name": { + "type": "string", + "maxLength": 255 } }, "required": [ - "results" + "type", + "email", + "role", + "name" ] }, - "LockEventItem": { + "SpaceSafeDto": { "type": "object", "properties": { - "eventType": { - "type": "string", - "enum": [ - "LOCKED" - ] - }, - "executionDate": { - "type": "string" - }, - "transactionHash": { - "type": "string" - }, - "holder": { - "type": "string" - }, - "amount": { + "chainId": { "type": "string" }, - "logIndex": { + "address": { "type": "string" } }, "required": [ - "eventType", - "executionDate", - "transactionHash", - "holder", - "amount", - "logIndex" + "chainId", + "address" ] }, - "UnlockEventItem": { + "AddressBookItem": { "type": "object", "properties": { - "eventType": { - "type": "string", - "enum": [ - "UNLOCKED" - ] - }, - "executionDate": { - "type": "string" - }, - "transactionHash": { - "type": "string" - }, - "holder": { - "type": "string" - }, - "amount": { + "name": { "type": "string" }, - "logIndex": { + "address": { "type": "string" }, - "unlockIndex": { - "type": "string" + "chainIds": { + "type": "array", + "items": { + "type": "string" + } } }, "required": [ - "eventType", - "executionDate", - "transactionHash", - "holder", - "amount", - "logIndex", - "unlockIndex" + "name", + "address", + "chainIds" ] }, - "WithdrawEventItem": { + "SpaceSetupSurveyDto": { "type": "object", "properties": { - "eventType": { + "slug": { "type": "string", - "enum": [ - "WITHDRAWN" - ] - }, - "executionDate": { - "type": "string" - }, - "transactionHash": { - "type": "string" - }, - "holder": { - "type": "string" - }, - "amount": { - "type": "string" - }, - "logIndex": { - "type": "string" + "example": "onboarding" }, - "unlockIndex": { - "type": "string" + "selections": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } + }, + "description": "Map from page id to selected option keys" } }, "required": [ - "eventType", - "executionDate", - "transactionHash", - "holder", - "amount", - "logIndex", - "unlockIndex" + "slug", + "selections" ] }, - "LockingEventPage": { + "CreateSpaceSetupDto": { "type": "object", "properties": { - "count": { - "type": "number", - "nullable": true + "name": { + "type": "string" }, - "next": { + "paymentLinkId": { "type": "string", - "nullable": true + "nullable": true, + "description": "The picked trial plan; its checkout starts the trial. Null applies the setup at once, which is refused once billing is enforced." }, - "previous": { - "type": "string", - "nullable": true + "safes": { + "description": "Safes to add when the trial starts. One seat per address, however many chains.", + "type": "array", + "items": { + "$ref": "#/components/schemas/SpaceSafeDto" + } }, - "results": { + "addressBookItems": { + "type": "array", + "items": { + "$ref": "#/components/schemas/AddressBookItem" + } + }, + "invites": { "type": "array", "items": { "oneOf": [ { - "$ref": "#/components/schemas/LockEventItem" - }, - { - "$ref": "#/components/schemas/UnlockEventItem" + "$ref": "#/components/schemas/WalletInviteUserDto" }, { - "$ref": "#/components/schemas/WithdrawEventItem" + "$ref": "#/components/schemas/EmailInviteUserDto" } ] } - } - }, - "required": [ - "results" - ] - }, - "Contract": { - "type": "object", - "properties": { - "address": { - "type": "string" - }, - "name": { - "type": "string" - }, - "displayName": { - "type": "string" - }, - "logoUri": { - "type": "string" }, - "contractAbi": { + "survey": { + "nullable": true, "type": "object", - "nullable": true - }, - "trustedForDelegateCall": { - "type": "boolean" + "allOf": [ + { + "$ref": "#/components/schemas/SpaceSetupSurveyDto" + } + ] + }, + "returnUrl": { + "type": "string", + "description": "Where the checkout returns to. Must be on an allowed redirect domain." } }, "required": [ - "address", "name", - "displayName", - "logoUri", - "trustedForDelegateCall" + "paymentLinkId", + "safes", + "addressBookItems", + "invites", + "survey", + "returnUrl" ] }, - "TransactionDataDto": { + "SpaceSetupCheckoutDto": { "type": "object", "properties": { - "data": { + "spaceId": { "type": "string", - "description": "Hexadecimal value" + "description": "Space UUID" }, - "to": { + "checkoutUrl": { "type": "string", - "description": "The target Ethereum address" + "nullable": true, + "description": "The checkout to redirect to. Null when no plan was given: the setup is applied already." } }, "required": [ - "data" + "spaceId", + "checkoutUrl" ] }, - "Operation": { - "type": "number", - "enum": [ - 0, - 1 - ], - "description": "Operation type: 0 for CALL, 1 for DELEGATE" - }, - "BaseDataDecoded": { + "SpaceSetupDto": { "type": "object", "properties": { - "method": { - "type": "string" + "status": { + "type": "string", + "enum": [ + "pending", + "applied" + ] }, - "parameters": { + "paymentLinkId": { + "type": "string", + "nullable": true + }, + "safes": { "type": "array", "items": { - "$ref": "#/components/schemas/DataDecodedParameter" + "$ref": "#/components/schemas/SpaceSafeDto" + } + }, + "addressBookItems": { + "type": "array", + "items": { + "$ref": "#/components/schemas/AddressBookItem" + } + }, + "invites": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WalletInviteUserDto" + }, + { + "$ref": "#/components/schemas/EmailInviteUserDto" + } + ] } + }, + "survey": { + "nullable": true, + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/SpaceSetupSurveyDto" + } + ] } }, "required": [ - "method" + "status", + "paymentLinkId", + "safes", + "addressBookItems", + "invites", + "survey" ] }, - "MultiSend": { + "UserDto": { "type": "object", "properties": { - "operation": { - "description": "Operation type: 0 for CALL, 1 for DELEGATE", - "allOf": [ - { - "$ref": "#/components/schemas/Operation" - } - ] - }, - "value": { - "type": "string" - }, - "dataDecoded": { - "$ref": "#/components/schemas/BaseDataDecoded" - }, - "to": { - "type": "string" - }, - "data": { - "type": "string", - "nullable": true, - "description": "Hexadecimal encoded data", - "pattern": "^0x[0-9a-fA-F]*$" + "id": { + "type": "number" } }, "required": [ - "operation", - "value", - "to", - "data" + "id" ] }, - "DataDecodedParameter": { + "SpaceMemberDto": { "type": "object", "properties": { + "role": { + "type": "string", + "enum": [ + "ADMIN", + "MEMBER" + ] + }, "name": { "type": "string" }, - "type": { + "invitedBy": { + "type": "number", + "nullable": true + }, + "inviteExpiresAt": { + "format": "date-time", + "type": "string", + "nullable": true + }, + "invitedByName": { "type": "string" }, - "value": { - "description": "Parameter value - typically a string, but may be an array of strings for array types (e.g., address[], uint256[])", - "oneOf": [ - { - "type": "string" - }, - { - "type": "array", - "items": { - "type": "string" - } - } + "status": { + "type": "string", + "enum": [ + "INVITED", + "ACTIVE", + "DECLINED" ] }, - "valueDecoded": { - "oneOf": [ - { - "$ref": "#/components/schemas/BaseDataDecoded" - }, - { - "type": "array", - "items": { - "$ref": "#/components/schemas/MultiSend" - } - }, - { - "type": "null" - } - ] + "user": { + "$ref": "#/components/schemas/UserDto" } }, "required": [ + "role", "name", - "type", - "value" + "invitedBy", + "inviteExpiresAt", + "status", + "user" ] }, - "DataDecoded": { + "GetSpaceResponse": { "type": "object", "properties": { - "method": { + "uuid": { + "type": "string", + "description": "Space UUID" + }, + "name": { "type": "string" }, - "parameters": { - "nullable": true, + "members": { + "description": "Members of the space. A pending (INVITED) member only sees their own membership row here, not the other members.", "type": "array", "items": { - "$ref": "#/components/schemas/DataDecodedParameter" + "$ref": "#/components/schemas/SpaceMemberDto" } }, - "accuracy": { + "memberCount": { + "type": "number", + "description": "Total count of ACTIVE members in the space", + "example": 5 + }, + "safeCount": { + "type": "number", + "description": "Total count of Safes in the space", + "example": 5 + }, + "experimentalFeatures": { + "type": "array", + "description": "Experimental features this Workspace has opted into.", + "items": { + "type": "string", + "enum": [ + "POLICY_RECIPIENT_ALLOWLIST" + ] + } + }, + "setupStatus": { "type": "string", "enum": [ - "FULL_MATCH", - "PARTIAL_MATCH", - "ONLY_FUNCTION_MATCH", - "NO_MATCH", - "UNKNOWN" + "pending", + "applied" ], - "default": "UNKNOWN" - } - }, - "required": [ - "method" - ] - }, - "AddRecoveryModuleDto": { - "type": "object", - "properties": { - "moduleAddress": { - "type": "string" + "nullable": true, + "description": "Status of the onboarding setup, or null for a Workspace created without one. Pending until the trial starts and the setup is applied." } }, "required": [ - "moduleAddress" + "uuid", + "name", + "members", + "memberCount", + "safeCount", + "experimentalFeatures", + "setupStatus" ] }, - "GetEstimationDto": { + "UpdateSpaceDto": { "type": "object", "properties": { - "to": { - "type": "string" - }, - "value": { + "name": { "type": "string" }, - "data": { + "status": { "type": "string", - "nullable": true - }, - "operation": { - "description": "Operation type: 0 for CALL, 1 for DELEGATE", - "allOf": [ - { - "$ref": "#/components/schemas/Operation" - } + "enum": [ + "ACTIVE" ] + }, + "experimentalFeatures": { + "type": "array", + "description": "Replaces the stored set; [] opts out of all. Omit to leave it unchanged.", + "items": { + "type": "string", + "enum": [ + "POLICY_RECIPIENT_ALLOWLIST" + ] + } } - }, - "required": [ - "to", - "value", - "operation" - ] + } }, - "EstimationResponse": { + "UpdateSpaceResponse": { "type": "object", - "properties": { - "currentNonce": { - "type": "number" - }, - "recommendedNonce": { - "type": "number" - }, - "safeTxGas": { - "type": "string" + "properties": { + "uuid": { + "type": "string", + "description": "Space UUID" } }, "required": [ - "currentNonce", - "recommendedNonce", - "safeTxGas" + "uuid" ] }, - "GasToken": { + "SpaceAuditLogEntryDto": { "type": "object", "properties": { - "address": { + "id": { "type": "string", - "description": "Gas token contract address", - "example": "0x0000000000000000000000000000000000000000" + "description": "Monotonic entry id (bigint serialized as string)" }, - "symbol": { + "eventType": { "type": "string", - "description": "The token's ticker symbol", - "example": "USDC" + "enum": [ + "SPACE_CREATED", + "SPACE_UPDATED", + "SPACE_DELETED", + "MEMBER_INVITED", + "MEMBER_INVITE_ACCEPTED", + "MEMBER_INVITE_DECLINED", + "MEMBER_INVITE_RENEWED", + "MEMBER_ROLE_UPDATED", + "MEMBER_ALIAS_UPDATED", + "MEMBER_REMOVED", + "MEMBER_LEFT", + "SAFE_ADDED", + "SAFE_REMOVED", + "ADDRESS_BOOK_UPSERTED", + "ADDRESS_BOOK_DELETED", + "ADDRESS_BOOK_REQUEST_CREATED", + "ADDRESS_BOOK_REQUEST_REJECTED", + "ADDRESS_BOOK_TAGS_UPDATED", + "ADDRESS_BOOK_TAG_CREATED", + "ADDRESS_BOOK_TAG_RENAMED", + "ADDRESS_BOOK_TAG_DELETED" + ] + }, + "actorUserId": { + "type": "number" + }, + "actor": { + "type": "string", + "description": "Resolved (and masked) display string of the acting user." + }, + "targetUser": { + "type": "string", + "nullable": true, + "description": "Resolved (and masked) display string of the affected user, when the event has one." + }, + "payload": { + "type": "object", + "description": "Event-specific payload, allowlisted per event type. Clients must treat every field as optional." + }, + "createdAt": { + "format": "date-time", + "type": "string" } }, "required": [ - "address", - "symbol" + "id", + "eventType", + "actorUserId", + "actor", + "targetUser", + "payload", + "createdAt" ] }, - "GasTokenPage": { + "SpaceAuditLogPage": { "type": "object", "properties": { "count": { @@ -8813,7 +12695,7 @@ "results": { "type": "array", "items": { - "$ref": "#/components/schemas/GasToken" + "$ref": "#/components/schemas/SpaceAuditLogEntryDto" } } }, @@ -8821,4152 +12703,4708 @@ "results" ] }, - "Origin": { - "type": "string", - "enum": [ - "SAFE_APP", - "WALLET_CONNECT", - "TX_BUILDER", - "NATIVE" - ], - "description": "Transaction origin. Defaults to NATIVE when omitted." - }, - "FeePreviewTransactionDto": { + "SpaceAuditLogActorDto": { "type": "object", "properties": { - "to": { - "type": "string" - }, - "value": { - "type": "string" - }, - "data": { - "type": "string" - }, - "operation": { - "description": "Operation type: 0 for CALL, 1 for DELEGATE", - "allOf": [ - { - "$ref": "#/components/schemas/Operation" - } - ] - }, - "gasToken": { - "type": "string", - "description": "Gas token address (0x0...0 for native token)", - "example": "0x0000000000000000000000000000000000000000" - }, - "numberSignatures": { - "type": "number", - "description": "Number of signatures required for execution", - "example": 2, - "minimum": 1 - }, - "nonce": { - "type": "string", - "description": "Safe nonce the transaction will use (uint256 string)", - "example": "42" - }, - "origin": { - "description": "Transaction origin. Defaults to NATIVE when omitted.", - "allOf": [ - { - "$ref": "#/components/schemas/Origin" - } - ] + "actorUserId": { + "type": "number" }, - "fiatCode": { + "actor": { "type": "string", - "description": "Fiat currency code for relay cost conversion (e.g. EUR, GBP). Defaults to USD.", - "example": "EUR" + "description": "Resolved (and masked) display string of the actor." } }, "required": [ - "to", - "value", - "data", - "operation", - "gasToken", - "numberSignatures", - "nonce" + "actorUserId", + "actor" ] }, - "FeePreviewTxData": { + "CreateSpaceSafesDto": { "type": "object", "properties": { - "chainId": { - "type": "string", - "description": "Chain ID", - "example": "1" - }, - "safeAddress": { - "type": "string", - "description": "Safe address", - "example": "0x..." - }, - "safeTxGas": { - "type": "string", - "description": "Safe transaction gas", - "example": "150000" - }, - "baseGas": { - "type": "string", - "description": "Base gas for relay overhead", - "example": "48564" - }, - "gasPrice": { - "type": "string", - "description": "Gas price per gas unit. Denominated in wei when `gasToken` is the native token (zero address), or in the ERC20 gas token atomic units per gas otherwise", - "example": "195000000000000" - }, - "gasToken": { - "type": "string", - "description": "Gas token address", - "example": "0x0000000000000000000000000000000000000000" - }, - "refundReceiver": { - "type": "string", - "description": "Refund receiver address", - "example": "0x0000000000000000000000000000000000000000" + "safes": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SpaceSafeDto" + } }, - "numberSignatures": { - "type": "number", - "description": "Number of signatures", - "example": 2 + "addressBookItems": { + "description": "Address book entries to upsert for the added Safes, in the same transaction: if either write fails, neither is kept.", + "type": "array", + "items": { + "$ref": "#/components/schemas/AddressBookItem" + } } }, "required": [ - "chainId", - "safeAddress", - "safeTxGas", - "baseGas", - "gasPrice", - "gasToken", - "refundReceiver", - "numberSignatures" + "safes" ] }, - "FeePreviewRelayCost": { + "GetSpacesSafesResponse": { "type": "object", "properties": { - "fiatCode": { - "type": "string", - "description": "Fiat currency code", - "example": "USD" + "safes": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } + }, + "example": { + "{chainId}": [ + "0x..." + ] + } }, - "fiatValue": { + "spaceUuid": { "type": "string", - "description": "Relay cost as a string", - "example": "0.0025" + "description": "Space UUID" } }, "required": [ - "fiatCode", - "fiatValue" + "safes", + "spaceUuid" ] }, - "FeePreviewValuationDetail": { + "GetSpaceSafeResponse": { "type": "object", "properties": { - "tokenAddress": { - "type": "string", - "description": "Token contract address (absent for native transfers)" - }, - "symbol": { - "type": "string", - "description": "Token symbol", - "example": "USDC" - }, - "amount": { - "type": "string", - "description": "Token amount", - "example": "1000" - }, - "priceUsd": { - "type": "number", - "description": "Token price in USD" - }, - "valueUsd": { - "type": "number", - "description": "Token value in USD" + "safes": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } + }, + "example": { + "{chainId}": [ + "0x..." + ] + } } }, "required": [ - "symbol", - "amount" + "safes" ] }, - "FeePreviewFeeBreakdown": { + "DeleteSpaceSafesDto": { "type": "object", "properties": { - "txValueUsd": { - "type": "number", - "description": "Transaction value in USD", - "example": 1000 - }, - "trailingVolumeUsd": { - "type": "number", - "description": "Trailing volume in USD that fed tier selection", - "example": 0 - }, - "tierBps": { - "type": "number", - "description": "Tier fee in basis points", - "example": 5 - }, - "gtfFeeUsd": { - "type": "number", - "description": "GTF fee in USD", - "example": 0.5 - }, - "relayCostUsd": { - "type": "number", - "description": "Relay cost in USD", - "example": 38.22 - }, - "totalUsd": { - "type": "number", - "description": "Total fee in USD", - "example": 38.72 - }, - "numberSignatures": { - "type": "number", - "description": "Number of signatures", - "example": 2 - }, - "valuationDetails": { + "safes": { "type": "array", "items": { - "$ref": "#/components/schemas/FeePreviewValuationDetail" + "$ref": "#/components/schemas/SpaceSafeDto" } } }, "required": [ - "txValueUsd", - "trailingVolumeUsd", - "tierBps", - "gtfFeeUsd", - "relayCostUsd", - "totalUsd", - "numberSignatures", - "valuationDetails" + "safes" ] }, - "FeePreviewResponse": { + "InviteUsersDto": { "type": "object", "properties": { - "txData": { - "$ref": "#/components/schemas/FeePreviewTxData" + "users": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WalletInviteUserDto" + }, + { + "$ref": "#/components/schemas/EmailInviteUserDto" + } + ] + } + } + }, + "required": [ + "users" + ] + }, + "Invitation": { + "type": "object", + "properties": { + "userId": { + "type": "number" }, - "relayCost": { - "description": "Relay cost. Present when the relay fee flow applies.", - "allOf": [ - { - "$ref": "#/components/schemas/FeePreviewRelayCost" - } + "name": { + "type": "string" + }, + "spaceUuid": { + "type": "string", + "description": "Space UUID" + }, + "role": { + "type": "string", + "enum": [ + "ADMIN", + "MEMBER" ] }, - "feeBreakdown": { - "description": "GTF fee breakdown, as returned by the fee-engine service. Present when the GTF fee flow applies.", - "allOf": [ - { - "$ref": "#/components/schemas/FeePreviewFeeBreakdown" - } + "status": { + "type": "string", + "enum": [ + "INVITED", + "ACTIVE", + "DECLINED" ] }, - "maxFeeCapUsd": { + "invitedBy": { "type": "number", - "description": "Maximum fee cap in USD (buffered max fee). Present when the GTF fee flow applies." + "nullable": true } }, "required": [ - "txData" + "userId", + "name", + "spaceUuid", + "role", + "status", + "invitedBy" ] }, - "TypedDataParameter": { + "AcceptInviteDto": { "type": "object", "properties": { "name": { - "type": "string" + "type": "string", + "maxLength": 255 + } + }, + "required": [ + "name" + ] + }, + "MemberUser": { + "type": "object", + "properties": { + "id": { + "type": "number" }, - "type": { - "type": "string" + "status": { + "type": "string", + "enum": [ + "PENDING", + "ACTIVE" + ] + }, + "email": { + "type": "string", + "nullable": true + }, + "address": { + "type": "string", + "nullable": true } }, "required": [ - "name", - "type" + "id", + "status", + "email", + "address" ] }, - "TypedDataDomain": { + "MemberDto": { "type": "object", "properties": { - "chainId": { + "id": { "type": "number" }, + "role": { + "type": "string", + "enum": [ + "ADMIN", + "MEMBER" + ] + }, + "status": { + "type": "string", + "enum": [ + "INVITED", + "ACTIVE", + "DECLINED" + ] + }, "name": { "type": "string" }, - "salt": { - "type": "string" + "alias": { + "type": "string", + "nullable": true }, - "verifyingContract": { + "invitedBy": { + "type": "number", + "nullable": true + }, + "inviteExpiresAt": { + "format": "date-time", + "type": "string", + "nullable": true + }, + "createdAt": { + "format": "date-time", "type": "string" }, - "version": { + "updatedAt": { + "format": "date-time", "type": "string" + }, + "user": { + "$ref": "#/components/schemas/MemberUser" } - } + }, + "required": [ + "id", + "role", + "status", + "name", + "invitedBy", + "createdAt", + "updatedAt", + "user" + ] }, - "TypedData": { + "MembersDto": { "type": "object", "properties": { - "domain": { - "$ref": "#/components/schemas/TypedDataDomain" - }, - "primaryType": { - "type": "string" - }, - "types": { - "type": "object", - "additionalProperties": { - "items": { - "$ref": "#/components/schemas/TypedDataParameter" - }, - "type": "array" + "members": { + "type": "array", + "items": { + "$ref": "#/components/schemas/MemberDto" } - }, - "message": { - "type": "object", - "additionalProperties": true } }, "required": [ - "domain", - "primaryType", - "types", - "message" + "members" ] }, - "AddressInfo": { + "UpdateRoleDto": { "type": "object", "properties": { - "value": { - "type": "string" - }, - "name": { - "type": "string", - "nullable": true - }, - "logoUri": { + "role": { "type": "string", - "nullable": true + "enum": [ + "ADMIN", + "MEMBER" + ] } }, "required": [ - "value" + "role" ] }, - "MessageConfirmation": { + "UpdateMemberAliasDto": { "type": "object", "properties": { - "owner": { - "$ref": "#/components/schemas/AddressInfo" - }, - "signature": { - "type": "string" + "alias": { + "type": "string", + "description": "The new alias for the member" } }, "required": [ - "owner", - "signature" + "alias" ] }, - "Message": { + "CounterfactualSafeDto": { "type": "object", "properties": { - "messageHash": { + "chainId": { "type": "string" }, - "status": { - "type": "string", - "enum": [ - "NEEDS_CONFIRMATION", - "CONFIRMED" - ] - }, - "logoUri": { - "type": "string", - "nullable": true - }, - "name": { - "type": "string", - "nullable": true + "address": { + "type": "string" }, - "message": { - "oneOf": [ - { - "type": "string" - }, - { - "$ref": "#/components/schemas/TypedData" - } - ] + "factoryAddress": { + "type": "string" }, - "creationTimestamp": { - "type": "number" + "masterCopy": { + "type": "string" }, - "modifiedTimestamp": { - "type": "number" + "saltNonce": { + "type": "string" }, - "confirmationsSubmitted": { - "type": "number" + "safeVersion": { + "type": "string" }, - "confirmationsRequired": { + "threshold": { "type": "number" }, - "proposedBy": { - "$ref": "#/components/schemas/AddressInfo" - }, - "confirmations": { + "owners": { "type": "array", "items": { - "$ref": "#/components/schemas/MessageConfirmation" + "type": "string" } }, - "preparedSignature": { + "fallbackHandler": { "type": "string", "nullable": true }, - "origin": { + "to": { "type": "string", "nullable": true - } - }, - "required": [ - "messageHash", - "status", - "message", - "creationTimestamp", - "modifiedTimestamp", - "confirmationsSubmitted", - "confirmationsRequired", - "proposedBy", - "confirmations" - ] - }, - "MessageItem": { - "type": "object", - "properties": { - "messageHash": { - "type": "string" - }, - "status": { - "type": "string", - "enum": [ - "NEEDS_CONFIRMATION", - "CONFIRMED" - ] }, - "logoUri": { - "type": "string", - "nullable": true + "data": { + "type": "string" }, - "name": { + "paymentToken": { "type": "string", "nullable": true }, - "message": { - "oneOf": [ - { - "type": "string" - }, - { - "$ref": "#/components/schemas/TypedData" - } - ] - }, - "creationTimestamp": { - "type": "number" - }, - "modifiedTimestamp": { - "type": "number" - }, - "confirmationsSubmitted": { - "type": "number" - }, - "confirmationsRequired": { - "type": "number" - }, - "proposedBy": { - "$ref": "#/components/schemas/AddressInfo" - }, - "confirmations": { - "type": "array", - "items": { - "$ref": "#/components/schemas/MessageConfirmation" - } - }, - "preparedSignature": { + "payment": { "type": "string", "nullable": true }, - "origin": { + "paymentReceiver": { "type": "string", "nullable": true - }, - "type": { - "type": "string", - "enum": [ - "MESSAGE" - ] } }, "required": [ - "messageHash", - "status", - "message", - "creationTimestamp", - "modifiedTimestamp", - "confirmationsSubmitted", - "confirmationsRequired", - "proposedBy", - "confirmations", - "type" + "chainId", + "address", + "factoryAddress", + "masterCopy", + "saltNonce", + "safeVersion", + "threshold", + "owners", + "data" ] }, - "DateLabel": { + "CreateCounterfactualSafesDto": { "type": "object", "properties": { - "type": { - "type": "string", - "enum": [ - "DATE_LABEL" - ] - }, - "timestamp": { - "type": "number" + "safes": { + "type": "array", + "items": { + "$ref": "#/components/schemas/CounterfactualSafeDto" + } } }, "required": [ - "type", - "timestamp" + "safes" ] }, - "MessagePage": { + "GetCounterfactualSafeItem": { "type": "object", "properties": { - "count": { - "type": "number", - "nullable": true + "address": { + "type": "string" }, - "next": { - "type": "string", - "nullable": true + "factoryAddress": { + "type": "string" }, - "previous": { - "type": "string", - "nullable": true + "masterCopy": { + "type": "string" }, - "results": { + "saltNonce": { + "type": "string" + }, + "safeVersion": { + "type": "string" + }, + "threshold": { + "type": "number" + }, + "owners": { "type": "array", "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/MessageItem" - }, - { - "$ref": "#/components/schemas/DateLabel" - } - ] + "type": "string" } - } - }, - "required": [ - "results" - ] - }, - "CreateMessageDto": { - "type": "object", - "properties": { - "message": { - "oneOf": [ - { - "type": "string" - }, - { - "$ref": "#/components/schemas/TypedData" - } - ] }, - "safeAppId": { - "type": "number", - "nullable": true, - "deprecated": true + "fallbackHandler": { + "type": "string", + "nullable": true }, - "signature": { + "to": { + "type": "string", + "nullable": true + }, + "data": { "type": "string" }, - "origin": { + "paymentToken": { + "type": "string", + "nullable": true + }, + "payment": { + "type": "string", + "nullable": true + }, + "paymentReceiver": { "type": "string", "nullable": true } }, "required": [ - "message", - "signature" + "address", + "factoryAddress", + "masterCopy", + "saltNonce", + "safeVersion", + "threshold", + "owners", + "fallbackHandler", + "to", + "data", + "paymentToken", + "payment", + "paymentReceiver" ] }, - "UpdateMessageSignatureDto": { + "GetCounterfactualSafesResponse": { "type": "object", "properties": { - "signature": { - "type": "string" + "safes": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/components/schemas/GetCounterfactualSafeItem" + } + }, + "example": { + "{chainId}": [ + { + "address": "0x...", + "factoryAddress": "0x...", + "masterCopy": "0x...", + "saltNonce": "1712000000000", + "safeVersion": "1.4.1", + "threshold": 1, + "owners": [ + "0x..." + ], + "fallbackHandler": "0x...", + "to": null, + "data": "0x...", + "paymentToken": null, + "payment": null, + "paymentReceiver": null + } + ] + } } }, "required": [ - "signature" + "safes" ] }, - "UserWallet": { + "DeleteCounterfactualSafeDto": { "type": "object", "properties": { - "id": { - "type": "number" + "chainId": { + "type": "string" }, "address": { "type": "string" } }, "required": [ - "id", + "chainId", "address" ] }, - "UserWithWallets": { + "DeleteCounterfactualSafesDto": { "type": "object", "properties": { - "id": { - "type": "number" - }, - "status": { - "type": "number", - "enum": [ - 0, - 1 - ] - }, - "wallets": { + "safes": { "type": "array", "items": { - "$ref": "#/components/schemas/UserWallet" + "$ref": "#/components/schemas/DeleteCounterfactualSafeDto" } } }, "required": [ - "id", - "status", - "wallets" + "safes" ] }, - "CreatedUserWithWallet": { + "SingleRecipientAnalysisResultDto": { "type": "object", "properties": { - "id": { - "type": "number" + "severity": { + "type": "string", + "description": "Severity level indicating the importance and risk", + "enum": [ + "OK", + "INFO", + "WARN", + "CRITICAL" + ] + }, + "type": { + "type": "string", + "description": "Recipient interaction status code", + "enum": [ + "NEW_RECIPIENT", + "RECURRING_RECIPIENT", + "LOW_ACTIVITY", + "FAILED" + ], + "example": "NEW_RECIPIENT" + }, + "title": { + "type": "string", + "description": "User-facing title of the finding" + }, + "description": { + "type": "string", + "description": "Detailed description explaining the finding and its implications" + }, + "error": { + "type": "string", + "description": "Error message for failed analysis" } }, "required": [ - "id" + "severity", + "type", + "title", + "description" ] }, - "WalletAddedToUser": { + "SingleRecipientAnalysisDto": { "type": "object", "properties": { - "id": { - "type": "number" + "RECIPIENT_INTERACTION": { + "description": "Analysis results related to recipient interaction history. Shows whether this is a new or recurring recipient.", + "example": [ + { + "severity": "INFO", + "type": "NEW_RECIPIENT", + "title": "New recipient", + "description": "This is the first time you are interacting with this recipient." + } + ], + "type": "array", + "items": { + "$ref": "#/components/schemas/SingleRecipientAnalysisResultDto" + } + }, + "RECIPIENT_ACTIVITY": { + "description": "Analysis results related to recipient activity. Shows whether this is a low activity recipient. (Available only for Safes)", + "example": [ + { + "severity": "WARN", + "type": "LOW_ACTIVITY", + "title": "Low activity recipient", + "description": "This address has few transactions." + } + ], + "type": "array", + "items": { + "$ref": "#/components/schemas/SingleRecipientAnalysisResultDto" + } + }, + "isSafe": { + "type": "boolean", + "description": "Indicates whether the analyzed recipient address is a Safe.", + "example": false } }, "required": [ - "id" + "RECIPIENT_INTERACTION", + "isSafe" ] }, - "SpaceAddressBookItemDto": { + "CounterpartyAnalysisRequestDto": { "type": "object", "properties": { - "name": { - "type": "string" - }, - "address": { - "type": "string" - }, - "chainIds": { - "type": "array", - "items": { - "type": "string" - } - }, - "createdBy": { + "to": { "type": "string", - "description": "Email or wallet address of the creator, \"Unknown user\" if the user has no display identity, or \"Deleted user\"" + "description": "Recipient address of the transaction." }, - "createdByUserId": { - "type": "number", - "description": "User ID of the creator" + "value": { + "type": "string", + "description": "Amount to send with the transaction." }, - "lastUpdatedBy": { + "data": { "type": "string", - "description": "Email or wallet address of the last editor, \"Unknown user\" if the user has no display identity, or \"Deleted user\"" + "description": "Hex-encoded data payload for the transaction." }, - "lastUpdatedByUserId": { + "operation": { "type": "number", - "description": "User ID of the last editor" - }, - "createdAt": { - "format": "date-time", - "type": "string" - }, - "updatedAt": { - "format": "date-time", - "type": "string" + "enum": [ + 0, + 1 + ], + "description": "Operation type: 0 for CALL, 1 for DELEGATECALL." } }, "required": [ - "name", - "address", - "chainIds", - "createdBy", - "createdByUserId", - "lastUpdatedBy", - "lastUpdatedByUserId", - "createdAt", - "updatedAt" + "to", + "value", + "data", + "operation" ] }, - "SpaceAddressBookDto": { + "RecipientResultDto": { "type": "object", "properties": { - "spaceUuid": { + "severity": { + "type": "string", + "description": "Severity level indicating the importance and risk", + "enum": [ + "OK", + "INFO", + "WARN", + "CRITICAL" + ] + }, + "type": { + "type": "string", + "description": "Bridge compatibility status code", + "enum": [ + "NEW_RECIPIENT", + "RECURRING_RECIPIENT", + "LOW_ACTIVITY", + "INCOMPATIBLE_SAFE", + "MISSING_OWNERSHIP", + "UNSUPPORTED_NETWORK", + "DIFFERENT_SAFE_SETUP", + "FAILED" + ], + "example": "MISSING_OWNERSHIP" + }, + "title": { + "type": "string", + "description": "User-facing title of the finding" + }, + "description": { + "type": "string", + "description": "Detailed description explaining the finding and its implications" + }, + "error": { "type": "string", - "description": "Space UUID" + "description": "Error message for failed analysis" }, - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SpaceAddressBookItemDto" - } + "targetChainId": { + "type": "string", + "description": "Target chain ID for bridge operations. Only present for BridgeStatus." } }, "required": [ - "spaceUuid", - "data" + "severity", + "type", + "title", + "description" ] }, - "AddressBookItem": { + "RecipientAnalysisDto": { "type": "object", "properties": { - "name": { - "type": "string" + "isSafe": { + "type": "boolean", + "description": "Indicates whether the analyzed recipient address is a Safe.", + "example": true }, - "address": { - "type": "string" + "RECIPIENT_INTERACTION": { + "description": "Analysis results related to recipient interaction history. Shows whether this is a new or recurring recipient.", + "example": [ + { + "severity": "INFO", + "type": "NEW_RECIPIENT", + "title": "New recipient", + "description": "This is the first time you are interacting with this recipient." + } + ], + "type": "array", + "items": { + "$ref": "#/components/schemas/RecipientResultDto" + } }, - "chainIds": { + "RECIPIENT_ACTIVITY": { + "description": "Analysis results related to recipient activity frequency. Shows whether this is a low activity recipient.", + "example": [ + { + "severity": "WARN", + "type": "LOW_ACTIVITY", + "title": "Low activity recipient", + "description": "This address has few transactions." + } + ], "type": "array", "items": { - "type": "string" + "$ref": "#/components/schemas/RecipientResultDto" + } + }, + "BRIDGE": { + "description": "Analysis results for cross-chain bridge operations. Identifies compatibility issues, ownership problems, or unsupported networks.", + "example": [ + { + "severity": "WARN", + "type": "MISSING_OWNERSHIP", + "title": "No ownership on target chain", + "description": "You do not have ownership of a Safe on the target chain.", + "targetChainId": "137" + } + ], + "type": "array", + "items": { + "$ref": "#/components/schemas/RecipientResultDto" } } }, "required": [ - "name", - "address", - "chainIds" + "isSafe" ] }, - "UpsertAddressBookItemsDto": { + "ContractAnalysisResultDto": { "type": "object", "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddressBookItem" - } + "severity": { + "type": "string", + "description": "Severity level indicating the importance and risk", + "enum": [ + "OK", + "INFO", + "WARN", + "CRITICAL" + ] + }, + "type": { + "type": "string", + "description": "Contract verification status code", + "enum": [ + "VERIFIED", + "NOT_VERIFIED", + "NOT_VERIFIED_BY_SAFE", + "VERIFICATION_UNAVAILABLE", + "NEW_CONTRACT", + "KNOWN_CONTRACT", + "UNEXPECTED_DELEGATECALL", + "UNOFFICIAL_FALLBACK_HANDLER", + "FAILED" + ], + "example": "VERIFIED" + }, + "title": { + "type": "string", + "description": "User-facing title of the finding" + }, + "description": { + "type": "string", + "description": "Detailed description explaining the finding and its implications" + }, + "error": { + "type": "string", + "description": "Error message for failed analysis" } }, "required": [ - "items" + "severity", + "type", + "title", + "description" ] }, - "AddressBookRequestItemDto": { + "FallbackHandlerInfoDto": { "type": "object", "properties": { - "id": { - "type": "number" - }, - "name": { - "type": "string" - }, "address": { - "type": "string" - }, - "chainIds": { - "type": "array", - "items": { - "type": "string" - } + "type": "string", + "description": "Address of the fallback handler contract" }, - "requestedBy": { + "name": { "type": "string", - "description": "Email or wallet address of the requester, \"Unknown user\" if the user has no display identity, or \"Deleted user\"" + "description": "Name of the fallback handler contract" }, - "requestedByUserId": { - "type": "number", - "description": "User ID of the requester" + "logoUrl": { + "type": "string", + "description": "Logo URL for the fallback handler contract" + } + }, + "required": [ + "address" + ] + }, + "FallbackHandlerAnalysisResultDto": { + "type": "object", + "properties": { + "severity": { + "type": "string", + "description": "Severity level indicating the importance and risk", + "enum": [ + "OK", + "INFO", + "WARN", + "CRITICAL" + ] }, - "reviewedBy": { + "type": { "type": "string", - "nullable": true, - "description": "Email or wallet address of the reviewing admin, \"Unknown user\", \"Deleted user\", or null when still PENDING" + "description": "Status code for unofficial fallback handler", + "enum": [ + "UNOFFICIAL_FALLBACK_HANDLER" + ], + "example": "VERIFIED" }, - "reviewedByUserId": { - "type": "number", - "nullable": true, - "description": "User ID of the reviewing admin, null when still PENDING" + "title": { + "type": "string", + "description": "User-facing title of the finding" }, - "status": { + "description": { "type": "string", - "enum": [ - "PENDING", - "APPROVED", - "REJECTED" - ] + "description": "Detailed description explaining the finding and its implications" }, - "createdAt": { - "format": "date-time", - "type": "string" + "error": { + "type": "string", + "description": "Error message for failed analysis" }, - "updatedAt": { - "format": "date-time", - "type": "string" + "fallbackHandler": { + "description": "Information about the fallback handler", + "allOf": [ + { + "$ref": "#/components/schemas/FallbackHandlerInfoDto" + } + ] } }, "required": [ - "id", - "name", - "address", - "chainIds", - "requestedBy", - "requestedByUserId", - "reviewedBy", - "reviewedByUserId", - "status", - "createdAt", - "updatedAt" + "severity", + "type", + "title", + "description" ] }, - "AddressBookRequestsDto": { + "ContractAnalysisDto": { "type": "object", "properties": { - "spaceUuid": { + "logoUrl": { "type": "string", - "description": "Space UUID" + "description": "Logo URL for the contract", + "example": "https://example.com/logo.png" }, - "data": { + "name": { + "type": "string", + "description": "Name of the contract", + "example": "Uniswap V3 Router" + }, + "CONTRACT_VERIFICATION": { + "description": "Analysis results for contract verification status. Shows whether contracts are verified and source code is available.", + "example": [ + { + "severity": "INFO", + "type": "VERIFIED", + "title": "Verified contract", + "description": "This contract has been verified and its source code is available" + } + ], + "type": "array", + "items": { + "$ref": "#/components/schemas/ContractAnalysisResultDto" + } + }, + "CONTRACT_INTERACTION": { + "description": "Analysis results related to contract interaction history. Shows whether this is a new or previously interacted contract.", + "example": [ + { + "severity": "INFO", + "type": "NEW_CONTRACT", + "title": "New contract", + "description": "This is the first time you are interacting with this contract" + } + ], "type": "array", "items": { - "$ref": "#/components/schemas/AddressBookRequestItemDto" + "$ref": "#/components/schemas/ContractAnalysisResultDto" } - } - }, - "required": [ - "spaceUuid", - "data" - ] - }, - "CreateAddressBookRequestDto": { - "type": "object", - "properties": { - "name": { - "type": "string", - "maxLength": 50, - "description": "Name of the proposed contact" }, - "address": { - "type": "string", - "description": "Address of the contact to propose for the space address book" + "DELEGATECALL": { + "description": "Analysis results for delegatecall operations. Identifies unexpected or potentially dangerous delegate calls.", + "example": [ + { + "severity": "CRITICAL", + "type": "UNEXPECTED_DELEGATECALL", + "title": "Unexpected delegatecall", + "description": "An unexpected delegatecall operation was detected that could be dangerous" + } + ], + "type": "array", + "items": { + "$ref": "#/components/schemas/ContractAnalysisResultDto" + } }, - "chainIds": { - "description": "Chain ids the contact applies to (at least one, duplicates are removed)", + "FALLBACK_HANDLER": { + "description": "Analysis results for setFallbackHandler operations. Identifies untrusted or unofficial fallback handlers in the transactions.", + "example": [ + { + "severity": "WARN", + "type": "UNOFFICIAL_FALLBACK_HANDLER", + "title": "Unofficial fallback handler", + "description": "Verify the fallback handler is trusted and secure before proceeding.", + "fallbackHandler": { + "address": "0x123", + "name": "CompatibilityFallbackHandler", + "logoUrl": "https://example.com/logo.png" + } + } + ], "type": "array", "items": { - "type": "string" + "$ref": "#/components/schemas/FallbackHandlerAnalysisResultDto" } } - }, - "required": [ - "name", - "address", - "chainIds" - ] - }, - "CreateSpaceDto": { - "type": "object", - "properties": { - "name": { - "type": "string" - } - }, - "required": [ - "name" - ] + } }, - "CreateSpaceResponse": { + "DeadlockAnalysisResultDto": { "type": "object", "properties": { - "name": { - "type": "string" + "severity": { + "type": "string", + "description": "Severity level indicating the importance and risk", + "enum": [ + "OK", + "INFO", + "WARN", + "CRITICAL" + ] }, - "uuid": { + "type": { "type": "string", - "description": "Space UUID" + "description": "Deadlock analysis status code", + "enum": [ + "DEADLOCK_DETECTED", + "NESTED_SAFE_WARNING", + "FAILED" + ], + "example": "DEADLOCK_DETECTED" + }, + "title": { + "type": "string", + "description": "User-facing title of the finding" + }, + "description": { + "type": "string", + "description": "Detailed description explaining the finding and its implications" + }, + "error": { + "type": "string", + "description": "Error message for failed analysis" } }, "required": [ - "name", - "uuid" + "severity", + "type", + "title", + "description" ] }, - "UserDto": { + "DeadlockAnalysisDto": { "type": "object", "properties": { - "id": { - "type": "number" + "DEADLOCK": { + "description": "Deadlock analysis findings. Identifies signing deadlock risks in nested Safe configurations.", + "example": [ + { + "severity": "CRITICAL", + "type": "DEADLOCK_DETECTED", + "title": "Signing deadlock risk detected", + "description": "This change may create a signing cycle between Safes and can permanently lock funds. You will not be allowed to proceed forward." + } + ], + "type": "array", + "items": { + "$ref": "#/components/schemas/DeadlockAnalysisResultDto" + } } - }, - "required": [ - "id" - ] + } }, - "SpaceMemberDto": { + "CounterpartyAnalysisDto": { "type": "object", "properties": { - "role": { - "type": "string", - "enum": [ - "ADMIN", - "MEMBER" - ] - }, - "name": { - "type": "string" - }, - "invitedBy": { - "type": "number", - "nullable": true - }, - "inviteExpiresAt": { - "format": "date-time", - "type": "string", - "nullable": true - }, - "invitedByName": { - "type": "string" + "recipient": { + "type": "object", + "description": "Recipient analysis results mapped by address. Contains recipient interaction history and bridge analysis.type: Record
.", + "additionalProperties": { + "$ref": "#/components/schemas/RecipientAnalysisDto" + }, + "example": { + "0x0000000000000000000000000000000000000000": { + "isSafe": true, + "RECIPIENT_INTERACTION": [ + { + "severity": "INFO", + "type": "NEW_RECIPIENT", + "title": "New recipient", + "description": "This is the first time you are interacting with this recipient" + } + ] + } + } }, - "status": { - "type": "string", - "enum": [ - "INVITED", - "ACTIVE", - "DECLINED" - ] + "contract": { + "type": "object", + "description": "Contract analysis results mapped by address. Contains contract verification, interaction history, and delegatecall analysis.type: Record.", + "additionalProperties": { + "$ref": "#/components/schemas/ContractAnalysisDto" + }, + "example": { + "0x0000000000000000000000000000000000000000": { + "CONTRACT_VERIFICATION": [ + { + "severity": "INFO", + "type": "VERIFIED", + "title": "Verified contract", + "description": "This contract has been verified and its source code is available" + } + ] + } + } }, - "user": { - "$ref": "#/components/schemas/UserDto" + "deadlock": { + "type": "object", + "description": "Deadlock analysis results mapped by Safe address. Contains signing deadlock risk findings for owner/threshold management transactions.", + "additionalProperties": { + "$ref": "#/components/schemas/DeadlockAnalysisDto" + }, + "example": { + "0x0000000000000000000000000000000000000000": { + "DEADLOCK": [ + { + "severity": "CRITICAL", + "type": "DEADLOCK_DETECTED", + "title": "Signing deadlock risk detected", + "description": "This change may create a signing cycle between Safes and can permanently lock funds. You will not be allowed to proceed forward." + } + ] + } + } } }, "required": [ - "role", - "name", - "invitedBy", - "inviteExpiresAt", - "status", - "user" + "recipient", + "contract", + "deadlock" ] }, - "GetSpaceResponse": { + "ConflictHeaderQueuedItem": { "type": "object", "properties": { - "uuid": { + "type": { "type": "string", - "description": "Space UUID" - }, - "name": { - "type": "string" - }, - "members": { - "description": "Members of the space. A pending (INVITED) member only sees their own membership row here, not the other members.", - "type": "array", - "items": { - "$ref": "#/components/schemas/SpaceMemberDto" - } - }, - "memberCount": { - "type": "number", - "description": "Total count of ACTIVE members in the space", - "example": 5 + "enum": [ + "CONFLICT_HEADER" + ] }, - "safeCount": { - "type": "number", - "description": "Total count of Safes in the space", - "example": 5 + "nonce": { + "type": "number" } }, "required": [ - "uuid", - "name", - "members", - "memberCount", - "safeCount" + "type", + "nonce" ] }, - "UpdateSpaceDto": { + "LabelQueuedItem": { "type": "object", "properties": { - "name": { - "type": "string" - }, - "status": { + "type": { "type": "string", "enum": [ - "ACTIVE" + "LABEL" ] + }, + "label": { + "type": "string" } - } + }, + "required": [ + "type", + "label" + ] }, - "UpdateSpaceResponse": { + "TransactionInfo": { "type": "object", "properties": { - "uuid": { + "type": { "type": "string", - "description": "Space UUID" + "enum": [ + "Bridge", + "Creation", + "Custom", + "NativeStakingDeposit", + "NativeStakingValidatorsExit", + "NativeStakingWithdraw", + "SettingsChange", + "Swap", + "SwapAndBridge", + "SwapOrder", + "SwapTransfer", + "Transfer", + "TwapOrder", + "VaultDeposit", + "VaultRedeem" + ] + }, + "humanDescription": { + "type": "string", + "nullable": true } }, "required": [ - "uuid" + "type" ] }, - "SpaceAuditLogEntryDto": { + "CreationTransactionInfo": { "type": "object", "properties": { - "id": { - "type": "string", - "description": "Monotonic entry id (bigint serialized as string)" - }, - "eventType": { + "type": { "type": "string", "enum": [ - "SPACE_CREATED", - "SPACE_UPDATED", - "SPACE_DELETED", - "MEMBER_INVITED", - "MEMBER_INVITE_ACCEPTED", - "MEMBER_INVITE_DECLINED", - "MEMBER_INVITE_RENEWED", - "MEMBER_ROLE_UPDATED", - "MEMBER_ALIAS_UPDATED", - "MEMBER_REMOVED", - "MEMBER_LEFT", - "SAFE_ADDED", - "SAFE_REMOVED", - "ADDRESS_BOOK_UPSERTED", - "ADDRESS_BOOK_DELETED" + "Creation" ] }, - "actorUserId": { - "type": "number" - }, - "actor": { + "humanDescription": { "type": "string", - "description": "Resolved (and masked) display string of the acting user." + "nullable": true }, - "targetUser": { - "type": "string", - "nullable": true, - "description": "Resolved (and masked) display string of the affected user, when the event has one." + "creator": { + "$ref": "#/components/schemas/AddressInfo" }, - "payload": { + "transactionHash": { + "type": "string" + }, + "implementation": { + "nullable": true, "type": "object", - "description": "Event-specific payload, allowlisted per event type. Clients must treat every field as optional." + "allOf": [ + { + "$ref": "#/components/schemas/AddressInfo" + } + ] }, - "createdAt": { - "format": "date-time", - "type": "string" + "factory": { + "$ref": "#/components/schemas/AddressInfo" + }, + "saltNonce": { + "type": "string", + "nullable": true } }, "required": [ - "id", - "eventType", - "actorUserId", - "actor", - "targetUser", - "payload", - "createdAt" + "type", + "creator", + "transactionHash" ] }, - "SpaceAuditLogPage": { + "CustomTransactionInfo": { "type": "object", "properties": { - "count": { - "type": "number", - "nullable": true + "type": { + "type": "string", + "enum": [ + "Custom" + ] }, - "next": { + "humanDescription": { "type": "string", "nullable": true }, - "previous": { + "to": { + "$ref": "#/components/schemas/AddressInfo" + }, + "dataSize": { + "type": "string" + }, + "value": { "type": "string", "nullable": true }, - "results": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SpaceAuditLogEntryDto" - } - } - }, - "required": [ - "results" - ] - }, - "SpaceAuditLogActorDto": { - "type": "object", - "properties": { - "actorUserId": { - "type": "number" + "isCancellation": { + "type": "boolean" }, - "actor": { + "methodName": { "type": "string", - "description": "Resolved (and masked) display string of the actor." + "nullable": true } }, "required": [ - "actorUserId", - "actor" + "type", + "to", + "dataSize", + "isCancellation" ] }, - "SpaceSafeDto": { + "MultiSendTransactionInfo": { "type": "object", "properties": { - "chainId": { - "type": "string" + "type": { + "type": "string", + "enum": [ + "Custom" + ] }, - "address": { + "humanDescription": { + "type": "string", + "nullable": true + }, + "to": { + "$ref": "#/components/schemas/AddressInfo" + }, + "dataSize": { "type": "string" + }, + "value": { + "type": "string", + "nullable": true + }, + "isCancellation": { + "type": "boolean" + }, + "methodName": { + "type": "string", + "enum": [ + "multiSend" + ] + }, + "actionCount": { + "type": "number" } }, "required": [ - "chainId", - "address" - ] - }, - "CreateSpaceSafesDto": { - "type": "object", - "properties": { - "safes": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SpaceSafeDto" - } - } - }, - "required": [ - "safes" - ] - }, - "GetSpaceSafeResponse": { - "type": "object", - "properties": { - "safes": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" - } - }, - "example": { - "{chainId}": [ - "0x..." - ] - } - } - }, - "required": [ - "safes" - ] - }, - "DeleteSpaceSafesDto": { - "type": "object", - "properties": { - "safes": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SpaceSafeDto" - } - } - }, - "required": [ - "safes" + "type", + "to", + "dataSize", + "isCancellation", + "methodName", + "actionCount" ] }, - "WalletInviteUserDto": { + "AddOwner": { "type": "object", "properties": { "type": { "type": "string", "enum": [ - "wallet" + "ADD_OWNER" ] }, - "address": { - "type": "string" - }, - "role": { - "type": "string", - "enum": [ - "ADMIN", - "MEMBER" - ] + "owner": { + "$ref": "#/components/schemas/AddressInfo" }, - "name": { - "type": "string", - "maxLength": 255 + "threshold": { + "type": "number" } }, "required": [ "type", - "address", - "role", - "name" + "owner", + "threshold" ] }, - "EmailInviteUserDto": { + "ChangeMasterCopy": { "type": "object", "properties": { "type": { "type": "string", "enum": [ - "email" + "CHANGE_MASTER_COPY" ] }, - "email": { - "type": "string", - "format": "email", - "maxLength": 255 - }, - "role": { + "implementation": { + "$ref": "#/components/schemas/AddressInfo" + } + }, + "required": [ + "type", + "implementation" + ] + }, + "ChangeThreshold": { + "type": "object", + "properties": { + "type": { "type": "string", "enum": [ - "ADMIN", - "MEMBER" + "CHANGE_THRESHOLD" ] }, - "name": { - "type": "string", - "maxLength": 255 + "threshold": { + "type": "number" } }, "required": [ "type", - "email", - "role", - "name" + "threshold" ] }, - "InviteUsersDto": { + "DeleteGuard": { "type": "object", "properties": { - "users": { - "type": "array", - "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/WalletInviteUserDto" - }, - { - "$ref": "#/components/schemas/EmailInviteUserDto" - } - ] - } + "type": { + "type": "string", + "enum": [ + "DELETE_GUARD" + ] } }, "required": [ - "users" + "type" ] }, - "Invitation": { + "DeleteModuleGuard": { "type": "object", "properties": { - "userId": { - "type": "number" - }, - "name": { - "type": "string" - }, - "spaceUuid": { - "type": "string", - "description": "Space UUID" - }, - "role": { + "type": { "type": "string", "enum": [ - "ADMIN", - "MEMBER" + "DELETE_MODULE_GUARD" ] - }, - "status": { + } + }, + "required": [ + "type" + ] + }, + "DisableModule": { + "type": "object", + "properties": { + "type": { "type": "string", "enum": [ - "INVITED", - "ACTIVE", - "DECLINED" + "DISABLE_MODULE" ] }, - "invitedBy": { - "type": "number", - "nullable": true + "module": { + "$ref": "#/components/schemas/AddressInfo" } }, "required": [ - "userId", - "name", - "spaceUuid", - "role", - "status", - "invitedBy" + "type", + "module" ] }, - "AcceptInviteDto": { + "EnableModule": { "type": "object", "properties": { - "name": { + "type": { "type": "string", - "maxLength": 255 + "enum": [ + "ENABLE_MODULE" + ] + }, + "module": { + "$ref": "#/components/schemas/AddressInfo" } }, "required": [ - "name" + "type", + "module" ] }, - "MemberUser": { + "RemoveOwner": { "type": "object", "properties": { - "id": { - "type": "number" - }, - "status": { + "type": { "type": "string", "enum": [ - "PENDING", - "ACTIVE" + "REMOVE_OWNER" ] }, - "email": { - "type": "string", - "nullable": true + "owner": { + "$ref": "#/components/schemas/AddressInfo" + }, + "threshold": { + "type": "number" } }, "required": [ - "id", - "status", - "email" + "type", + "owner", + "threshold" ] }, - "MemberDto": { + "SetFallbackHandler": { "type": "object", "properties": { - "id": { - "type": "number" - }, - "role": { + "type": { "type": "string", "enum": [ - "ADMIN", - "MEMBER" + "SET_FALLBACK_HANDLER" ] }, - "status": { + "handler": { + "$ref": "#/components/schemas/AddressInfo" + } + }, + "required": [ + "type", + "handler" + ] + }, + "SetGuard": { + "type": "object", + "properties": { + "type": { "type": "string", "enum": [ - "INVITED", - "ACTIVE", - "DECLINED" + "SET_GUARD" ] }, - "name": { - "type": "string" - }, - "alias": { - "type": "string", - "nullable": true - }, - "invitedBy": { - "type": "number", - "nullable": true - }, - "inviteExpiresAt": { - "format": "date-time", - "type": "string", - "nullable": true - }, - "createdAt": { - "format": "date-time", - "type": "string" - }, - "updatedAt": { - "format": "date-time", - "type": "string" - }, - "user": { - "$ref": "#/components/schemas/MemberUser" + "guard": { + "$ref": "#/components/schemas/AddressInfo" } }, "required": [ - "id", - "role", - "status", - "name", - "invitedBy", - "createdAt", - "updatedAt", - "user" + "type", + "guard" ] }, - "MembersDto": { + "SetModuleGuard": { "type": "object", "properties": { - "members": { - "type": "array", - "items": { - "$ref": "#/components/schemas/MemberDto" - } + "type": { + "type": "string", + "enum": [ + "SET_MODULE_GUARD" + ] + }, + "moduleGuard": { + "$ref": "#/components/schemas/AddressInfo" } }, "required": [ - "members" + "type", + "moduleGuard" ] }, - "UpdateRoleDto": { + "SettingsChange": { "type": "object", "properties": { - "role": { + "type": { "type": "string", "enum": [ - "ADMIN", - "MEMBER" + "ADD_OWNER", + "CHANGE_MASTER_COPY", + "CHANGE_THRESHOLD", + "DELETE_GUARD", + "DELETE_MODULE_GUARD", + "DISABLE_MODULE", + "ENABLE_MODULE", + "REMOVE_OWNER", + "SET_FALLBACK_HANDLER", + "SET_GUARD", + "SET_MODULE_GUARD", + "SWAP_OWNER" ] } }, "required": [ - "role" + "type" ] }, - "UpdateMemberAliasDto": { + "SwapOwner": { "type": "object", "properties": { - "alias": { + "type": { "type": "string", - "description": "The new alias for the member" + "enum": [ + "SWAP_OWNER" + ] + }, + "oldOwner": { + "$ref": "#/components/schemas/AddressInfo" + }, + "newOwner": { + "$ref": "#/components/schemas/AddressInfo" } }, "required": [ - "alias" + "type", + "oldOwner", + "newOwner" ] }, - "CounterfactualSafeDto": { + "SettingsChangeTransaction": { "type": "object", "properties": { - "chainId": { - "type": "string" - }, - "address": { - "type": "string" - }, - "factoryAddress": { - "type": "string" - }, - "masterCopy": { - "type": "string" - }, - "saltNonce": { - "type": "string" - }, - "safeVersion": { - "type": "string" - }, - "threshold": { - "type": "number" - }, - "owners": { - "type": "array", - "items": { - "type": "string" - } - }, - "fallbackHandler": { - "type": "string", - "nullable": true - }, - "to": { + "type": { "type": "string", - "nullable": true - }, - "data": { - "type": "string" + "enum": [ + "SettingsChange" + ] }, - "paymentToken": { + "humanDescription": { "type": "string", "nullable": true }, - "payment": { - "type": "string", - "nullable": true + "dataDecoded": { + "$ref": "#/components/schemas/DataDecoded" }, - "paymentReceiver": { - "type": "string", - "nullable": true - } - }, - "required": [ - "chainId", - "address", - "factoryAddress", - "masterCopy", - "saltNonce", - "safeVersion", - "threshold", - "owners", - "data" - ] - }, - "CreateCounterfactualSafesDto": { - "type": "object", - "properties": { - "safes": { - "type": "array", - "items": { - "$ref": "#/components/schemas/CounterfactualSafeDto" - } + "settingsInfo": { + "oneOf": [ + { + "$ref": "#/components/schemas/AddOwner" + }, + { + "$ref": "#/components/schemas/ChangeMasterCopy" + }, + { + "$ref": "#/components/schemas/ChangeThreshold" + }, + { + "$ref": "#/components/schemas/DeleteGuard" + }, + { + "$ref": "#/components/schemas/DeleteModuleGuard" + }, + { + "$ref": "#/components/schemas/DisableModule" + }, + { + "$ref": "#/components/schemas/EnableModule" + }, + { + "$ref": "#/components/schemas/RemoveOwner" + }, + { + "$ref": "#/components/schemas/SetFallbackHandler" + }, + { + "$ref": "#/components/schemas/SetGuard" + }, + { + "$ref": "#/components/schemas/SetModuleGuard" + }, + { + "$ref": "#/components/schemas/SwapOwner" + } + ] } }, "required": [ - "safes" + "type", + "dataDecoded", + "settingsInfo" ] }, - "GetCounterfactualSafeItem": { + "Erc20Transfer": { "type": "object", "properties": { - "address": { - "type": "string" - }, - "factoryAddress": { - "type": "string" - }, - "masterCopy": { - "type": "string" + "type": { + "type": "string", + "enum": [ + "ERC20" + ] }, - "saltNonce": { + "tokenAddress": { "type": "string" }, - "safeVersion": { + "value": { "type": "string" }, - "threshold": { - "type": "number" - }, - "owners": { - "type": "array", - "items": { - "type": "string" - } - }, - "fallbackHandler": { + "tokenName": { "type": "string", "nullable": true }, - "to": { + "tokenSymbol": { "type": "string", "nullable": true }, - "data": { - "type": "string" - }, - "paymentToken": { + "logoUri": { "type": "string", "nullable": true }, - "payment": { - "type": "string", + "decimals": { + "type": "number", "nullable": true }, - "paymentReceiver": { - "type": "string", + "trusted": { + "type": "boolean", "nullable": true + }, + "imitation": { + "type": "boolean" } }, "required": [ - "address", - "factoryAddress", - "masterCopy", - "saltNonce", - "safeVersion", - "threshold", - "owners", - "fallbackHandler", - "to", - "data", - "paymentToken", - "payment", - "paymentReceiver" - ] - }, - "GetCounterfactualSafesResponse": { - "type": "object", - "properties": { - "safes": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetCounterfactualSafeItem" - } - }, - "example": { - "{chainId}": [ - { - "address": "0x...", - "factoryAddress": "0x...", - "masterCopy": "0x...", - "saltNonce": "1712000000000", - "safeVersion": "1.4.1", - "threshold": 1, - "owners": [ - "0x..." - ], - "fallbackHandler": "0x...", - "to": null, - "data": "0x...", - "paymentToken": null, - "payment": null, - "paymentReceiver": null - } - ] - } - } - }, - "required": [ - "safes" + "type", + "tokenAddress", + "value", + "imitation" ] }, - "DeleteCounterfactualSafeDto": { + "Erc721Transfer": { "type": "object", "properties": { - "chainId": { + "type": { + "type": "string", + "enum": [ + "ERC721" + ] + }, + "tokenAddress": { "type": "string" }, - "address": { + "tokenId": { "type": "string" + }, + "tokenName": { + "type": "string", + "nullable": true + }, + "tokenSymbol": { + "type": "string", + "nullable": true + }, + "logoUri": { + "type": "string", + "nullable": true + }, + "trusted": { + "type": "boolean", + "nullable": true } }, "required": [ - "chainId", - "address" + "type", + "tokenAddress", + "tokenId" ] }, - "DeleteCounterfactualSafesDto": { + "NativeCoinTransfer": { "type": "object", "properties": { - "safes": { - "type": "array", - "items": { - "$ref": "#/components/schemas/DeleteCounterfactualSafeDto" - } + "type": { + "type": "string", + "enum": [ + "NATIVE_COIN" + ] + }, + "value": { + "type": "string", + "nullable": true } }, "required": [ - "safes" + "type" ] }, - "SurveyOptionDto": { + "Transfer": { "type": "object", "properties": { - "key": { - "type": "string" + "type": { + "type": "string", + "enum": [ + "NATIVE_COIN", + "ERC20", + "ERC721" + ] + } + }, + "required": [ + "type" + ] + }, + "TransferTransactionInfo": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "Transfer" + ] }, - "label": { - "type": "string" + "humanDescription": { + "type": "string", + "nullable": true }, - "description": { - "type": "string" + "sender": { + "$ref": "#/components/schemas/AddressInfo" }, - "icon": { - "type": "string" + "recipient": { + "$ref": "#/components/schemas/AddressInfo" + }, + "direction": { + "type": "string", + "enum": [ + "INCOMING", + "OUTGOING", + "UNKNOWN" + ] + }, + "transferInfo": { + "oneOf": [ + { + "$ref": "#/components/schemas/Erc20Transfer" + }, + { + "$ref": "#/components/schemas/Erc721Transfer" + }, + { + "$ref": "#/components/schemas/NativeCoinTransfer" + } + ], + "allOf": [ + { + "$ref": "#/components/schemas/Transfer" + } + ] } }, "required": [ - "key", - "label" + "type", + "sender", + "recipient", + "direction", + "transferInfo" ] }, - "SurveyPageDto": { + "BridgeFee": { "type": "object", "properties": { - "id": { + "tokenAddress": { "type": "string" }, - "title": { + "integratorFee": { "type": "string" }, - "subtitle": { - "type": "string", - "nullable": true - }, - "multiSelect": { - "type": "boolean" - }, - "options": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SurveyOptionDto" - } + "lifiFee": { + "type": "string" } }, "required": [ - "id", - "title", - "subtitle", - "multiSelect", - "options" + "tokenAddress", + "integratorFee", + "lifiFee" ] }, - "SurveyContentDto": { + "TokenInfo": { "type": "object", "properties": { - "pages": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SurveyPageDto" - } + "address": { + "type": "string", + "description": "The token address" + }, + "decimals": { + "type": "number", + "description": "The token decimals" + }, + "logoUri": { + "type": "string", + "nullable": true, + "description": "The logo URI for the token" + }, + "name": { + "type": "string", + "description": "The token name" + }, + "symbol": { + "type": "string", + "description": "The token symbol" + }, + "trusted": { + "type": "boolean", + "description": "The token trusted status" } }, "required": [ - "pages" + "address", + "decimals", + "name", + "symbol", + "trusted" ] }, - "SurveyDto": { + "BridgeAndSwapTransactionInfo": { "type": "object", "properties": { - "id": { - "type": "number" + "type": { + "type": "string", + "enum": [ + "SwapAndBridge" + ] + }, + "humanDescription": { + "type": "string", + "nullable": true + }, + "fromToken": { + "$ref": "#/components/schemas/TokenInfo" + }, + "recipient": { + "$ref": "#/components/schemas/AddressInfo" + }, + "explorerUrl": { + "type": "string", + "nullable": true + }, + "status": { + "type": "string", + "enum": [ + "NOT_FOUND", + "INVALID", + "PENDING", + "DONE", + "FAILED", + "UNKNOWN", + "AWAITING_EXECUTION" + ] + }, + "substatus": { + "type": "string", + "enum": [ + "WAIT_SOURCE_CONFIRMATIONS", + "WAIT_DESTINATION_TRANSACTION", + "BRIDGE_NOT_AVAILABLE", + "CHAIN_NOT_AVAILABLE", + "REFUND_IN_PROGRESS", + "UNKNOWN_ERROR", + "COMPLETED", + "PARTIAL", + "REFUNDED", + "INSUFFICIENT_ALLOWANCE", + "INSUFFICIENT_BALANCE", + "OUT_OF_GAS", + "EXPIRED", + "SLIPPAGE_EXCEEDED", + "UNKNOWN_FAILED_ERROR", + "UNKNOWN", + "AWAITING_EXECUTION" + ] + }, + "fees": { + "nullable": true, + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/BridgeFee" + } + ] }, - "slug": { + "fromAmount": { "type": "string" }, - "version": { - "type": "number" - }, - "title": { + "toChain": { "type": "string" }, - "subtitle": { + "toToken": { + "nullable": true, + "type": "object", + "allOf": [ + { + "$ref": "#/components/schemas/TokenInfo" + } + ] + }, + "toAmount": { "type": "string", "nullable": true - }, - "surveyContent": { - "$ref": "#/components/schemas/SurveyContentDto" } }, "required": [ - "id", - "slug", - "version", - "title", - "subtitle", - "surveyContent" + "type", + "fromToken", + "recipient", + "explorerUrl", + "status", + "substatus", + "fees", + "fromAmount", + "toChain", + "toToken", + "toAmount" ] }, - "SpaceSurveyResponseDto": { + "SwapOrderTransactionInfo": { "type": "object", "properties": { - "surveyVersion": { - "type": "number" + "type": { + "type": "string", + "enum": [ + "SwapOrder" + ] }, - "selections": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" - } - }, - "description": "Map from page id → selected option keys" + "humanDescription": { + "type": "string", + "nullable": true }, - "submittedAt": { - "format": "date-time", - "type": "string" + "uid": { + "type": "string", + "description": "The order UID" }, - "updatedAt": { - "format": "date-time", - "type": "string" + "status": { + "type": "string", + "enum": [ + "presignaturePending", + "open", + "fulfilled", + "cancelled", + "expired", + "unknown" + ] }, - "answeredByUserId": { + "kind": { + "type": "string", + "enum": [ + "buy", + "sell", + "unknown" + ] + }, + "orderClass": { + "type": "string", + "enum": [ + "market", + "limit", + "liquidity", + "unknown" + ] + }, + "validUntil": { "type": "number", - "nullable": true - } - }, - "required": [ - "surveyVersion", - "selections", - "submittedAt", - "updatedAt", - "answeredByUserId" - ] - }, - "SurveyStateDto": { - "type": "object", - "properties": { - "survey": { - "$ref": "#/components/schemas/SurveyDto" + "description": "The timestamp when the order expires" }, - "surveyResponse": { - "nullable": true, - "type": "object", + "sellAmount": { + "type": "string", + "description": "The sell token raw amount (no decimals)" + }, + "buyAmount": { + "type": "string", + "description": "The buy token raw amount (no decimals)" + }, + "executedSellAmount": { + "type": "string", + "description": "The executed sell token raw amount (no decimals)" + }, + "executedBuyAmount": { + "type": "string", + "description": "The executed buy token raw amount (no decimals)" + }, + "sellToken": { + "description": "The sell token of the order", "allOf": [ { - "$ref": "#/components/schemas/SpaceSurveyResponseDto" + "$ref": "#/components/schemas/TokenInfo" } ] - } - }, - "required": [ - "survey", - "surveyResponse" - ] - }, - "SubmitSurveyResponseDto": { - "type": "object", - "properties": { - "selections": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" + }, + "buyToken": { + "description": "The buy token of the order", + "allOf": [ + { + "$ref": "#/components/schemas/TokenInfo" } - }, - "description": "Map from page id → selected option keys", - "example": { - "use_cases": [ - "run_payments", - "hold_assets" - ] - } - } - }, - "required": [ - "selections" - ] - }, - "SurveyResponseResultDto": { - "type": "object", - "properties": { - "id": { - "type": "number" + ] }, - "spaceUuid": { + "explorerUrl": { "type": "string", - "description": "Space UUID" - }, - "surveySlug": { - "type": "string" + "description": "The URL to the explorer page of the order" }, - "surveyVersion": { - "type": "number" + "executedFee": { + "type": "string", + "description": "The amount of fees paid for this order." }, - "selections": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" + "executedFeeToken": { + "description": "The token in which the fee was paid, expressed by SURPLUS tokens (BUY tokens for SELL orders and SELL tokens for BUY orders).", + "allOf": [ + { + "$ref": "#/components/schemas/TokenInfo" } - } + ] }, - "submittedAt": { - "format": "date-time", - "type": "string" + "receiver": { + "type": "string", + "nullable": true, + "description": "The (optional) address to receive the proceeds of the trade" }, - "updatedAt": { - "format": "date-time", + "owner": { "type": "string" }, - "answeredByUserId": { - "type": "number", - "nullable": true + "fullAppData": { + "type": "object", + "nullable": true, + "description": "The App Data for this order" } }, "required": [ - "id", - "spaceUuid", - "surveySlug", - "surveyVersion", - "selections", - "submittedAt", - "updatedAt", - "answeredByUserId" + "type", + "uid", + "status", + "kind", + "orderClass", + "validUntil", + "sellAmount", + "buyAmount", + "executedSellAmount", + "executedBuyAmount", + "sellToken", + "buyToken", + "explorerUrl", + "executedFee", + "executedFeeToken", + "owner" ] }, - "FeatureKey": { - "type": "string", - "enum": [ - "safe_seats" - ], - "description": "Feature key from the entitlements catalog." - }, - "BinaryEntitlement": { + "SwapTransactionInfo": { "type": "object", "properties": { - "feature": { - "description": "Feature key from the entitlements catalog.", - "allOf": [ - { - "$ref": "#/components/schemas/FeatureKey" - } - ] - }, - "enabled": { - "type": "boolean", - "description": "Whether the plan grants the feature at all. A metered feature reports its quota and usage even when this is false." - }, "type": { "type": "string", "enum": [ - "binary" + "Swap" ] - } - }, - "required": [ - "feature", - "enabled", - "type" - ] - }, - "ValueEntitlement": { - "type": "object", - "properties": { - "feature": { - "description": "Feature key from the entitlements catalog.", + }, + "humanDescription": { + "type": "string", + "nullable": true + }, + "recipient": { + "$ref": "#/components/schemas/AddressInfo" + }, + "fees": { + "nullable": true, + "type": "object", "allOf": [ { - "$ref": "#/components/schemas/FeatureKey" + "$ref": "#/components/schemas/BridgeFee" } ] }, - "enabled": { - "type": "boolean", - "description": "Whether the plan grants the feature at all. A metered feature reports its quota and usage even when this is false." + "fromToken": { + "$ref": "#/components/schemas/TokenInfo" }, - "type": { - "type": "string", - "enum": [ - "value" - ] + "fromAmount": { + "type": "string" }, - "value": { + "toToken": { + "$ref": "#/components/schemas/TokenInfo" + }, + "toAmount": { + "type": "string" + }, + "lifiExplorerUrl": { "type": "string", "nullable": true } }, "required": [ - "feature", - "enabled", "type", - "value" + "recipient", + "fees", + "fromToken", + "fromAmount", + "toToken", + "toAmount", + "lifiExplorerUrl" ] }, - "MeteredEntitlement": { + "SwapTransferTransactionInfo": { "type": "object", "properties": { - "feature": { - "description": "Feature key from the entitlements catalog.", + "type": { + "type": "string", + "enum": [ + "SwapTransfer" + ] + }, + "humanDescription": { + "type": "string", + "nullable": true + }, + "sender": { + "$ref": "#/components/schemas/AddressInfo" + }, + "recipient": { + "$ref": "#/components/schemas/AddressInfo" + }, + "direction": { + "type": "string" + }, + "transferInfo": { + "oneOf": [ + { + "$ref": "#/components/schemas/Erc20Transfer" + }, + { + "$ref": "#/components/schemas/Erc721Transfer" + }, + { + "$ref": "#/components/schemas/NativeCoinTransfer" + } + ], "allOf": [ { - "$ref": "#/components/schemas/FeatureKey" + "$ref": "#/components/schemas/Transfer" } ] }, - "enabled": { - "type": "boolean", - "description": "Whether the plan grants the feature at all. A metered feature reports its quota and usage even when this is false." + "uid": { + "type": "string", + "description": "The order UID" }, - "type": { + "status": { "type": "string", "enum": [ - "metered" + "presignaturePending", + "open", + "fulfilled", + "cancelled", + "expired", + "unknown" ] }, - "quota": { - "type": "number", - "nullable": true, - "description": "The plan's quota, never inflated to match usage; null means unlimited." + "kind": { + "type": "string", + "enum": [ + "buy", + "sell", + "unknown" + ] }, - "used": { + "orderClass": { + "type": "string", + "enum": [ + "market", + "limit", + "liquidity", + "unknown" + ] + }, + "validUntil": { "type": "number", - "description": "May legally exceed `quota`." + "description": "The timestamp when the order expires" }, - "resetsAt": { - "format": "date-time", + "sellAmount": { "type": "string", - "nullable": true, - "description": "Null for stock-type features (seats) that have no reset window." - } - }, - "required": [ - "feature", - "enabled", - "type", - "quota", - "used", - "resetsAt" - ] - }, - "EntitlementsPlan": { - "type": "object", - "properties": { - "id": { + "description": "The sell token raw amount (no decimals)" + }, + "buyAmount": { "type": "string", - "description": "Plan identifier in the billing service" + "description": "The buy token raw amount (no decimals)" }, - "name": { + "executedSellAmount": { "type": "string", - "nullable": true + "description": "The executed sell token raw amount (no decimals)" }, - "cycleEndsAt": { - "format": "date-time", + "executedBuyAmount": { "type": "string", - "nullable": true, - "description": "End of the current billing cycle" - } - }, - "required": [ - "id", - "name", - "cycleEndsAt" - ] - }, - "EntitlementsResponse": { - "type": "object", - "properties": { - "plan": { - "nullable": true, - "description": "Null when the workspace has no active subscription.", - "type": "object", + "description": "The executed buy token raw amount (no decimals)" + }, + "sellToken": { + "description": "The sell token of the order", "allOf": [ { - "$ref": "#/components/schemas/EntitlementsPlan" + "$ref": "#/components/schemas/TokenInfo" } ] }, - "entitlements": { - "type": "array", - "description": "One entry per catalog feature. Which fields an entry carries is decided by `type`: a metered one always carries quota, usage and its reset window, and the others never do.", - "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/BinaryEntitlement" - }, - { - "$ref": "#/components/schemas/ValueEntitlement" - }, - { - "$ref": "#/components/schemas/MeteredEntitlement" - } - ], - "discriminator": { - "propertyName": "type", - "mapping": { - "binary": "#/components/schemas/BinaryEntitlement", - "value": "#/components/schemas/ValueEntitlement", - "metered": "#/components/schemas/MeteredEntitlement" - } + "buyToken": { + "description": "The buy token of the order", + "allOf": [ + { + "$ref": "#/components/schemas/TokenInfo" } - } - } - }, - "required": [ - "plan", - "entitlements" - ] - }, - "SafeList": { - "type": "object", - "properties": { - "safes": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "safes" - ] - }, - "RelayDto": { - "type": "object", - "properties": { - "version": { - "type": "string" + ] + }, + "explorerUrl": { + "type": "string", + "description": "The URL to the explorer page of the order" }, - "to": { - "type": "string" + "executedFee": { + "type": "string", + "description": "The amount of fees paid for this order." }, - "data": { - "type": "string" + "executedFeeToken": { + "description": "The token in which the fee was paid, expressed by SURPLUS tokens (BUY tokens for SELL orders and SELL tokens for BUY orders).", + "allOf": [ + { + "$ref": "#/components/schemas/TokenInfo" + } + ] }, - "gasLimit": { + "receiver": { "type": "string", "nullable": true, - "description": "Accepted for backward compatibility and validation; not forwarded to the relay provider." + "description": "The (optional) address to receive the proceeds of the trade" }, - "safeTxHash": { - "type": "string", - "description": "Safe transaction hash for relay-fee eligibility check" + "owner": { + "type": "string" }, - "acceptUnverifiedSimulation": { - "type": "boolean", - "description": "Set to true to proceed with the relay when a previous attempt returned INDETERMINATE_SIMULATION. The user has acknowledged the simulation could not be completed and accepts the risk." + "fullAppData": { + "type": "object", + "nullable": true, + "description": "The App Data for this order" } }, "required": [ - "version", - "to", - "data" + "type", + "sender", + "recipient", + "direction", + "transferInfo", + "uid", + "status", + "kind", + "orderClass", + "validUntil", + "sellAmount", + "buyAmount", + "executedSellAmount", + "executedBuyAmount", + "sellToken", + "buyToken", + "explorerUrl", + "executedFee", + "executedFeeToken", + "owner" ] }, - "Relay": { + "DurationAuto": { "type": "object", "properties": { - "taskId": { - "type": "string" + "durationType": { + "type": "string", + "enum": [ + "AUTO" + ] } }, "required": [ - "taskId" + "durationType" ] }, - "RelayErrorResponse": { + "DurationLimit": { "type": "object", "properties": { - "code": { + "durationType": { "type": "string", "enum": [ - "SIMULATION_FAILED", - "INDETERMINATE_SIMULATION" - ], - "description": "Stable identifier of the error condition. The frontend MUST branch on this value (not on `message`, which is informational and may change)." - }, - "message": { - "type": "string", - "description": "Human-readable description of the error. Informational only; do not parse." + "LIMIT_DURATION" + ] }, - "statusCode": { - "type": "number", - "example": 422 + "duration": { + "type": "string" } }, "required": [ - "code", - "message", - "statusCode" + "durationType", + "duration" ] }, - "RelayTaskStatusReceipt": { + "StartTimeAtMining": { "type": "object", "properties": { - "transactionHash": { + "startType": { "type": "string", - "example": "0x4e4bb4493b2183061c3a0106ea96604edcc84f83313dbc0ab718abb1523d1042" - } - }, - "required": [ - "transactionHash" - ] - }, - "RelayTaskStatus": { - "type": "object", - "properties": { - "status": { - "type": "number", - "description": "Relay task status code: 100=Pending, 110=Submitted, 200=Included, 400=Rejected, 500=Reverted", "enum": [ - 100, - 110, - 200, - 400, - 500 - ], - "example": 200 - }, - "receipt": { - "description": "On-chain receipt. Only present when status is 200 (Included) or 500 (Reverted)", - "allOf": [ - { - "$ref": "#/components/schemas/RelayTaskStatusReceipt" - } + "AT_MINING_TIME" ] } }, "required": [ - "status" + "startType" ] }, - "RelaysRemaining": { + "StartTimeAtEpoch": { "type": "object", "properties": { - "remaining": { - "type": "number" + "startType": { + "type": "string", + "enum": [ + "AT_EPOCH" + ] }, - "limit": { + "epoch": { "type": "number" } }, "required": [ - "remaining", - "limit" - ] - }, - "SafeAppProvider": { - "type": "object", - "properties": { - "url": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "required": [ - "url", - "name" + "startType", + "epoch" ] }, - "SafeAppAccessControl": { + "TwapOrderTransactionInfo": { "type": "object", "properties": { "type": { - "type": "string" + "type": "string", + "enum": [ + "TwapOrder" + ] }, - "value": { - "nullable": true, - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "type" - ] - }, - "SafeAppSocialProfile": { - "type": "object", - "properties": { - "platform": { + "humanDescription": { + "type": "string", + "nullable": true + }, + "status": { "type": "string", + "description": "The TWAP status", "enum": [ - "DISCORD", - "GITHUB", - "TWITTER", - "TELEGRAM", - "UNKNOWN" + "presignaturePending", + "open", + "fulfilled", + "cancelled", + "expired", + "unknown" ] }, - "url": { - "type": "string" - } - }, - "required": [ - "platform", - "url" - ] - }, - "SafeApp": { - "type": "object", - "properties": { - "id": { - "type": "number" + "kind": { + "type": "string", + "enum": [ + "buy", + "sell", + "unknown" + ] }, - "url": { - "type": "string" + "class": { + "type": "string", + "enum": [ + "market", + "limit", + "liquidity", + "unknown" + ] }, - "name": { - "type": "string" + "activeOrderUid": { + "type": "string", + "nullable": true, + "description": "The order UID of the active order, or null if none is active" }, - "iconUrl": { + "validUntil": { + "type": "number", + "description": "The timestamp when the TWAP expires" + }, + "sellAmount": { + "type": "string", + "description": "The sell token raw amount (no decimals)" + }, + "buyAmount": { + "type": "string", + "description": "The buy token raw amount (no decimals)" + }, + "executedSellAmount": { + "type": "string", + "nullable": true, + "description": "The executed sell token raw amount (no decimals), or null if there are too many parts" + }, + "executedBuyAmount": { + "type": "string", + "nullable": true, + "description": "The executed buy token raw amount (no decimals), or null if there are too many parts" + }, + "executedFee": { "type": "string", - "nullable": true + "nullable": true, + "description": "The executed surplus fee raw amount (no decimals), or null if there are too many parts" }, - "description": { - "type": "string" + "executedFeeToken": { + "description": "The token in which the fee was paid, expressed by SURPLUS tokens (BUY tokens for SELL orders and SELL tokens for BUY orders).", + "allOf": [ + { + "$ref": "#/components/schemas/TokenInfo" + } + ] }, - "chainIds": { - "type": "array", - "items": { - "type": "string" - } + "sellToken": { + "description": "The sell token of the TWAP", + "allOf": [ + { + "$ref": "#/components/schemas/TokenInfo" + } + ] }, - "provider": { - "nullable": true, - "type": "object", + "buyToken": { + "description": "The buy token of the TWAP", "allOf": [ { - "$ref": "#/components/schemas/SafeAppProvider" + "$ref": "#/components/schemas/TokenInfo" } ] }, - "accessControl": { - "$ref": "#/components/schemas/SafeAppAccessControl" + "receiver": { + "type": "string", + "description": "The address to receive the proceeds of the trade" }, - "tags": { - "type": "array", - "items": { - "type": "string" - } + "owner": { + "type": "string" }, - "features": { - "type": "array", - "items": { - "type": "string" - } + "fullAppData": { + "type": "object", + "nullable": true, + "description": "The App Data for this TWAP" }, - "developerWebsite": { + "numberOfParts": { "type": "string", - "nullable": true + "description": "The number of parts in the TWAP" }, - "socialProfiles": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SafeAppSocialProfile" - } + "partSellAmount": { + "type": "string", + "description": "The amount of sellToken to sell in each part" }, - "featured": { - "type": "boolean" + "minPartLimit": { + "type": "string", + "description": "The amount of buyToken that must be bought in each part" + }, + "timeBetweenParts": { + "type": "number", + "description": "The duration of the TWAP interval" + }, + "durationOfPart": { + "description": "Whether the TWAP is valid for the entire interval or not", + "oneOf": [ + { + "$ref": "#/components/schemas/DurationAuto" + }, + { + "$ref": "#/components/schemas/DurationLimit" + } + ] + }, + "startTime": { + "description": "The start time of the TWAP", + "oneOf": [ + { + "$ref": "#/components/schemas/StartTimeAtMining" + }, + { + "$ref": "#/components/schemas/StartTimeAtEpoch" + } + ] } }, "required": [ - "id", - "url", - "name", - "description", - "chainIds", - "accessControl", - "tags", - "features", - "socialProfiles", - "featured" + "type", + "status", + "kind", + "validUntil", + "sellAmount", + "buyAmount", + "executedFeeToken", + "sellToken", + "buyToken", + "receiver", + "owner", + "numberOfParts", + "partSellAmount", + "minPartLimit", + "timeBetweenParts", + "durationOfPart", + "startTime" ] }, - "SafeState": { + "NativeStakingDepositTransactionInfo": { "type": "object", "properties": { - "address": { - "$ref": "#/components/schemas/AddressInfo" + "type": { + "type": "string", + "enum": [ + "NativeStakingDeposit" + ] }, - "chainId": { - "type": "string" + "humanDescription": { + "type": "string", + "nullable": true }, - "nonce": { + "status": { + "type": "string", + "enum": [ + "NOT_STAKED", + "ACTIVATING", + "DEPOSIT_IN_PROGRESS", + "ACTIVE", + "EXIT_REQUESTED", + "EXITING", + "EXITED", + "SLASHED" + ] + }, + "estimatedEntryTime": { "type": "number" }, - "threshold": { + "estimatedExitTime": { "type": "number" }, - "owners": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AddressInfo" - } + "estimatedWithdrawalTime": { + "type": "number" }, - "implementation": { - "$ref": "#/components/schemas/AddressInfo" + "fee": { + "type": "number" }, - "modules": { - "nullable": true, - "type": "array", - "items": { - "$ref": "#/components/schemas/AddressInfo" - } + "monthlyNrr": { + "type": "number" }, - "fallbackHandler": { - "nullable": true, - "type": "object", - "allOf": [ - { - "$ref": "#/components/schemas/AddressInfo" - } - ] + "annualNrr": { + "type": "number" }, - "guard": { - "nullable": true, - "type": "object", - "allOf": [ - { - "$ref": "#/components/schemas/AddressInfo" - } - ] + "value": { + "type": "string" }, - "version": { - "type": "string", - "nullable": true + "numValidators": { + "type": "number" }, - "implementationVersionState": { - "type": "string", - "enum": [ - "UP_TO_DATE", - "OUTDATED", - "UNKNOWN" - ] + "expectedAnnualReward": { + "type": "string" }, - "collectiblesTag": { - "type": "string", - "nullable": true + "expectedMonthlyReward": { + "type": "string" }, - "txQueuedTag": { - "type": "string", - "nullable": true + "expectedFiatAnnualReward": { + "type": "number" }, - "txHistoryTag": { - "type": "string", - "nullable": true + "expectedFiatMonthlyReward": { + "type": "number" }, - "messagesTag": { - "type": "string", - "nullable": true + "tokenInfo": { + "$ref": "#/components/schemas/TokenInfo" + }, + "validators": { + "nullable": true, + "description": "Populated after transaction has been executed", + "type": "array", + "items": { + "type": "string" + } } }, "required": [ - "address", - "chainId", - "nonce", - "threshold", - "owners", - "implementation", - "implementationVersionState" + "type", + "status", + "estimatedEntryTime", + "estimatedExitTime", + "estimatedWithdrawalTime", + "fee", + "monthlyNrr", + "annualNrr", + "value", + "numValidators", + "expectedAnnualReward", + "expectedMonthlyReward", + "expectedFiatAnnualReward", + "expectedFiatMonthlyReward", + "tokenInfo" ] }, - "SafeNonces": { + "NativeStakingValidatorsExitTransactionInfo": { "type": "object", "properties": { - "currentNonce": { + "type": { + "type": "string", + "enum": [ + "NativeStakingValidatorsExit" + ] + }, + "humanDescription": { + "type": "string", + "nullable": true + }, + "status": { + "type": "string", + "enum": [ + "NOT_STAKED", + "ACTIVATING", + "DEPOSIT_IN_PROGRESS", + "ACTIVE", + "EXIT_REQUESTED", + "EXITING", + "EXITED", + "SLASHED" + ] + }, + "estimatedExitTime": { "type": "number" }, - "recommendedNonce": { + "estimatedWithdrawalTime": { "type": "number" - } - }, - "required": [ - "currentNonce", - "recommendedNonce" - ] - }, - "SafeOverview": { - "type": "object", - "properties": { - "address": { - "$ref": "#/components/schemas/AddressInfo" }, - "chainId": { + "value": { "type": "string" }, - "threshold": { + "numValidators": { "type": "number" }, - "owners": { + "tokenInfo": { + "$ref": "#/components/schemas/TokenInfo" + }, + "validators": { "type": "array", "items": { - "$ref": "#/components/schemas/AddressInfo" + "type": "string" } - }, - "fiatTotal": { - "type": "string" - }, - "queued": { - "type": "number" - }, - "awaitingConfirmation": { - "type": "number", - "nullable": true } }, "required": [ - "address", - "chainId", - "threshold", - "owners", - "fiatTotal", - "queued" + "type", + "status", + "estimatedExitTime", + "estimatedWithdrawalTime", + "value", + "numValidators", + "tokenInfo", + "validators" ] }, - "SingleRecipientAnalysisResultDto": { + "NativeStakingWithdrawTransactionInfo": { "type": "object", "properties": { - "severity": { + "type": { "type": "string", - "description": "Severity level indicating the importance and risk", "enum": [ - "OK", - "INFO", - "WARN", - "CRITICAL" + "NativeStakingWithdraw" ] }, - "type": { + "humanDescription": { "type": "string", - "description": "Recipient interaction status code", - "enum": [ - "NEW_RECIPIENT", - "RECURRING_RECIPIENT", - "LOW_ACTIVITY", - "FAILED" - ], - "example": "NEW_RECIPIENT" + "nullable": true }, - "title": { - "type": "string", - "description": "User-facing title of the finding" + "value": { + "type": "string" }, - "description": { - "type": "string", - "description": "Detailed description explaining the finding and its implications" + "tokenInfo": { + "$ref": "#/components/schemas/TokenInfo" }, - "error": { - "type": "string", - "description": "Error message for failed analysis" + "validators": { + "type": "array", + "items": { + "type": "string" + } } }, "required": [ - "severity", "type", - "title", - "description" + "value", + "tokenInfo", + "validators" ] }, - "SingleRecipientAnalysisDto": { + "VaultInfo": { "type": "object", "properties": { - "RECIPIENT_INTERACTION": { - "description": "Analysis results related to recipient interaction history. Shows whether this is a new or recurring recipient.", - "example": [ - { - "severity": "INFO", - "type": "NEW_RECIPIENT", - "title": "New recipient", - "description": "This is the first time you are interacting with this recipient." - } - ], - "type": "array", - "items": { - "$ref": "#/components/schemas/SingleRecipientAnalysisResultDto" - } + "address": { + "type": "string" }, - "RECIPIENT_ACTIVITY": { - "description": "Analysis results related to recipient activity. Shows whether this is a low activity recipient. (Available only for Safes)", - "example": [ - { - "severity": "WARN", - "type": "LOW_ACTIVITY", - "title": "Low activity recipient", - "description": "This address has few transactions." - } - ], - "type": "array", - "items": { - "$ref": "#/components/schemas/SingleRecipientAnalysisResultDto" - } + "name": { + "type": "string" }, - "isSafe": { - "type": "boolean", - "description": "Indicates whether the analyzed recipient address is a Safe.", - "example": false + "description": { + "type": "string" + }, + "dashboardUri": { + "type": "string", + "nullable": true + }, + "logoUri": { + "type": "string" } }, "required": [ - "RECIPIENT_INTERACTION", - "isSafe" + "address", + "name", + "description", + "logoUri" ] }, - "CounterpartyAnalysisRequestDto": { + "VaultExtraReward": { "type": "object", "properties": { - "to": { - "type": "string", - "description": "Recipient address of the transaction." + "tokenInfo": { + "$ref": "#/components/schemas/TokenInfo" }, - "value": { - "type": "string", - "description": "Amount to send with the transaction." + "nrr": { + "type": "number" }, - "data": { - "type": "string", - "description": "Hex-encoded data payload for the transaction." + "claimable": { + "type": "string" }, - "operation": { - "type": "number", - "enum": [ - 0, - 1 - ], - "description": "Operation type: 0 for CALL, 1 for DELEGATECALL." + "claimableNext": { + "type": "string" } }, "required": [ - "to", - "value", - "data", - "operation" + "tokenInfo", + "nrr", + "claimable", + "claimableNext" ] }, - "RecipientResultDto": { + "VaultDepositTransactionInfo": { "type": "object", "properties": { - "severity": { + "type": { "type": "string", - "description": "Severity level indicating the importance and risk", "enum": [ - "OK", - "INFO", - "WARN", - "CRITICAL" + "VaultDeposit" ] }, - "type": { + "humanDescription": { "type": "string", - "description": "Bridge compatibility status code", - "enum": [ - "NEW_RECIPIENT", - "RECURRING_RECIPIENT", - "LOW_ACTIVITY", - "INCOMPATIBLE_SAFE", - "MISSING_OWNERSHIP", - "UNSUPPORTED_NETWORK", - "DIFFERENT_SAFE_SETUP", - "FAILED" - ], - "example": "MISSING_OWNERSHIP" + "nullable": true }, - "title": { - "type": "string", - "description": "User-facing title of the finding" + "value": { + "type": "string" + }, + "baseNrr": { + "type": "number" + }, + "fee": { + "type": "number" + }, + "tokenInfo": { + "$ref": "#/components/schemas/TokenInfo" + }, + "vaultInfo": { + "$ref": "#/components/schemas/VaultInfo" + }, + "currentReward": { + "type": "string" + }, + "additionalRewardsNrr": { + "type": "number" }, - "description": { - "type": "string", - "description": "Detailed description explaining the finding and its implications" + "additionalRewards": { + "type": "array", + "items": { + "$ref": "#/components/schemas/VaultExtraReward" + } }, - "error": { - "type": "string", - "description": "Error message for failed analysis" + "expectedMonthlyReward": { + "type": "string" }, - "targetChainId": { - "type": "string", - "description": "Target chain ID for bridge operations. Only present for BridgeStatus." + "expectedAnnualReward": { + "type": "string" } }, "required": [ - "severity", "type", - "title", - "description" + "value", + "baseNrr", + "fee", + "tokenInfo", + "vaultInfo", + "currentReward", + "additionalRewardsNrr", + "additionalRewards", + "expectedMonthlyReward", + "expectedAnnualReward" ] }, - "RecipientAnalysisDto": { + "VaultRedeemTransactionInfo": { "type": "object", "properties": { - "isSafe": { - "type": "boolean", - "description": "Indicates whether the analyzed recipient address is a Safe.", - "example": true + "type": { + "type": "string", + "enum": [ + "VaultRedeem" + ] }, - "RECIPIENT_INTERACTION": { - "description": "Analysis results related to recipient interaction history. Shows whether this is a new or recurring recipient.", - "example": [ - { - "severity": "INFO", - "type": "NEW_RECIPIENT", - "title": "New recipient", - "description": "This is the first time you are interacting with this recipient." - } - ], - "type": "array", - "items": { - "$ref": "#/components/schemas/RecipientResultDto" - } + "humanDescription": { + "type": "string", + "nullable": true }, - "RECIPIENT_ACTIVITY": { - "description": "Analysis results related to recipient activity frequency. Shows whether this is a low activity recipient.", - "example": [ - { - "severity": "WARN", - "type": "LOW_ACTIVITY", - "title": "Low activity recipient", - "description": "This address has few transactions." - } - ], - "type": "array", - "items": { - "$ref": "#/components/schemas/RecipientResultDto" - } + "value": { + "type": "string" }, - "BRIDGE": { - "description": "Analysis results for cross-chain bridge operations. Identifies compatibility issues, ownership problems, or unsupported networks.", - "example": [ - { - "severity": "WARN", - "type": "MISSING_OWNERSHIP", - "title": "No ownership on target chain", - "description": "You do not have ownership of a Safe on the target chain.", - "targetChainId": "137" - } - ], + "baseNrr": { + "type": "number" + }, + "fee": { + "type": "number" + }, + "tokenInfo": { + "$ref": "#/components/schemas/TokenInfo" + }, + "vaultInfo": { + "$ref": "#/components/schemas/VaultInfo" + }, + "currentReward": { + "type": "string" + }, + "additionalRewardsNrr": { + "type": "number" + }, + "additionalRewards": { "type": "array", "items": { - "$ref": "#/components/schemas/RecipientResultDto" + "$ref": "#/components/schemas/VaultExtraReward" } } }, "required": [ - "isSafe" + "type", + "value", + "baseNrr", + "fee", + "tokenInfo", + "vaultInfo", + "currentReward", + "additionalRewardsNrr", + "additionalRewards" ] }, - "ContractAnalysisResultDto": { + "ModuleExecutionInfo": { "type": "object", "properties": { - "severity": { - "type": "string", - "description": "Severity level indicating the importance and risk", - "enum": [ - "OK", - "INFO", - "WARN", - "CRITICAL" - ] - }, "type": { "type": "string", - "description": "Contract verification status code", "enum": [ - "VERIFIED", - "NOT_VERIFIED", - "NOT_VERIFIED_BY_SAFE", - "VERIFICATION_UNAVAILABLE", - "NEW_CONTRACT", - "KNOWN_CONTRACT", - "UNEXPECTED_DELEGATECALL", - "UNOFFICIAL_FALLBACK_HANDLER", - "FAILED" - ], - "example": "VERIFIED" - }, - "title": { - "type": "string", - "description": "User-facing title of the finding" - }, - "description": { - "type": "string", - "description": "Detailed description explaining the finding and its implications" + "MODULE" + ] }, - "error": { - "type": "string", - "description": "Error message for failed analysis" + "address": { + "$ref": "#/components/schemas/AddressInfo" } }, "required": [ - "severity", "type", - "title", - "description" + "address" ] }, - "FallbackHandlerInfoDto": { + "MultisigExecutionInfo": { "type": "object", "properties": { - "address": { + "type": { "type": "string", - "description": "Address of the fallback handler contract" + "enum": [ + "MULTISIG" + ] }, - "name": { - "type": "string", - "description": "Name of the fallback handler contract" + "nonce": { + "type": "number" }, - "logoUrl": { - "type": "string", - "description": "Logo URL for the fallback handler contract" + "confirmationsRequired": { + "type": "number" + }, + "confirmationsSubmitted": { + "type": "number" + }, + "missingSigners": { + "nullable": true, + "type": "array", + "items": { + "$ref": "#/components/schemas/AddressInfo" + } } }, "required": [ - "address" + "type", + "nonce", + "confirmationsRequired", + "confirmationsSubmitted" ] }, - "FallbackHandlerAnalysisResultDto": { + "Transaction": { "type": "object", "properties": { - "severity": { - "type": "string", - "description": "Severity level indicating the importance and risk", - "enum": [ - "OK", - "INFO", - "WARN", - "CRITICAL" - ] - }, - "type": { - "type": "string", - "description": "Status code for unofficial fallback handler", - "enum": [ - "UNOFFICIAL_FALLBACK_HANDLER" + "txInfo": { + "oneOf": [ + { + "$ref": "#/components/schemas/CreationTransactionInfo" + }, + { + "$ref": "#/components/schemas/CustomTransactionInfo" + }, + { + "$ref": "#/components/schemas/MultiSendTransactionInfo" + }, + { + "$ref": "#/components/schemas/SettingsChangeTransaction" + }, + { + "$ref": "#/components/schemas/TransferTransactionInfo" + }, + { + "$ref": "#/components/schemas/SwapOrderTransactionInfo" + }, + { + "$ref": "#/components/schemas/BridgeAndSwapTransactionInfo" + }, + { + "$ref": "#/components/schemas/SwapTransactionInfo" + }, + { + "$ref": "#/components/schemas/SwapTransferTransactionInfo" + }, + { + "$ref": "#/components/schemas/TwapOrderTransactionInfo" + }, + { + "$ref": "#/components/schemas/NativeStakingDepositTransactionInfo" + }, + { + "$ref": "#/components/schemas/NativeStakingValidatorsExitTransactionInfo" + }, + { + "$ref": "#/components/schemas/NativeStakingWithdrawTransactionInfo" + }, + { + "$ref": "#/components/schemas/VaultDepositTransactionInfo" + }, + { + "$ref": "#/components/schemas/VaultRedeemTransactionInfo" + } ], - "example": "VERIFIED" - }, - "title": { - "type": "string", - "description": "User-facing title of the finding" - }, - "description": { - "type": "string", - "description": "Detailed description explaining the finding and its implications" - }, - "error": { - "type": "string", - "description": "Error message for failed analysis" - }, - "fallbackHandler": { - "description": "Information about the fallback handler", "allOf": [ { - "$ref": "#/components/schemas/FallbackHandlerInfoDto" + "$ref": "#/components/schemas/TransactionInfo" } ] - } - }, - "required": [ - "severity", - "type", - "title", - "description" - ] - }, - "ContractAnalysisDto": { - "type": "object", - "properties": { - "logoUrl": { + }, + "id": { + "type": "string" + }, + "txHash": { "type": "string", - "description": "Logo URL for the contract", - "example": "https://example.com/logo.png" + "nullable": true }, - "name": { + "timestamp": { + "type": "number" + }, + "txStatus": { "type": "string", - "description": "Name of the contract", - "example": "Uniswap V3 Router" + "enum": [ + "SUCCESS", + "FAILED", + "CANCELLED", + "AWAITING_CONFIRMATIONS", + "AWAITING_EXECUTION" + ] }, - "CONTRACT_VERIFICATION": { - "description": "Analysis results for contract verification status. Shows whether contracts are verified and source code is available.", - "example": [ + "executionInfo": { + "oneOf": [ { - "severity": "INFO", - "type": "VERIFIED", - "title": "Verified contract", - "description": "This contract has been verified and its source code is available" - } - ], - "type": "array", - "items": { - "$ref": "#/components/schemas/ContractAnalysisResultDto" - } - }, - "CONTRACT_INTERACTION": { - "description": "Analysis results related to contract interaction history. Shows whether this is a new or previously interacted contract.", - "example": [ + "$ref": "#/components/schemas/MultisigExecutionInfo" + }, { - "severity": "INFO", - "type": "NEW_CONTRACT", - "title": "New contract", - "description": "This is the first time you are interacting with this contract" + "$ref": "#/components/schemas/ModuleExecutionInfo" } ], - "type": "array", - "items": { - "$ref": "#/components/schemas/ContractAnalysisResultDto" - } + "nullable": true }, - "DELEGATECALL": { - "description": "Analysis results for delegatecall operations. Identifies unexpected or potentially dangerous delegate calls.", - "example": [ + "safeAppInfo": { + "nullable": true, + "type": "object", + "allOf": [ { - "severity": "CRITICAL", - "type": "UNEXPECTED_DELEGATECALL", - "title": "Unexpected delegatecall", - "description": "An unexpected delegatecall operation was detected that could be dangerous" + "$ref": "#/components/schemas/SafeAppInfo" } - ], - "type": "array", - "items": { - "$ref": "#/components/schemas/ContractAnalysisResultDto" - } + ] }, - "FALLBACK_HANDLER": { - "description": "Analysis results for setFallbackHandler operations. Identifies untrusted or unofficial fallback handlers in the transactions.", - "example": [ - { - "severity": "WARN", - "type": "UNOFFICIAL_FALLBACK_HANDLER", - "title": "Unofficial fallback handler", - "description": "Verify the fallback handler is trusted and secure before proceeding.", - "fallbackHandler": { - "address": "0x123", - "name": "CompatibilityFallbackHandler", - "logoUrl": "https://example.com/logo.png" - } - } - ], - "type": "array", - "items": { - "$ref": "#/components/schemas/FallbackHandlerAnalysisResultDto" - } + "note": { + "type": "string", + "nullable": true } - } + }, + "required": [ + "txInfo", + "id", + "timestamp", + "txStatus" + ] }, - "DeadlockAnalysisResultDto": { + "TransactionQueuedItem": { "type": "object", "properties": { - "severity": { - "type": "string", - "description": "Severity level indicating the importance and risk", - "enum": [ - "OK", - "INFO", - "WARN", - "CRITICAL" - ] - }, "type": { "type": "string", - "description": "Deadlock analysis status code", "enum": [ - "DEADLOCK_DETECTED", - "NESTED_SAFE_WARNING", - "FAILED" - ], - "example": "DEADLOCK_DETECTED" - }, - "title": { - "type": "string", - "description": "User-facing title of the finding" + "TRANSACTION" + ] }, - "description": { - "type": "string", - "description": "Detailed description explaining the finding and its implications" + "transaction": { + "$ref": "#/components/schemas/Transaction" }, - "error": { + "conflictType": { "type": "string", - "description": "Error message for failed analysis" + "enum": [ + "None", + "HasNext", + "End" + ] } }, "required": [ - "severity", "type", - "title", - "description" - ] - }, - "DeadlockAnalysisDto": { - "type": "object", - "properties": { - "DEADLOCK": { - "description": "Deadlock analysis findings. Identifies signing deadlock risks in nested Safe configurations.", - "example": [ - { - "severity": "CRITICAL", - "type": "DEADLOCK_DETECTED", - "title": "Signing deadlock risk detected", - "description": "This change may create a signing cycle between Safes and can permanently lock funds. You will not be allowed to proceed forward." - } - ], - "type": "array", - "items": { - "$ref": "#/components/schemas/DeadlockAnalysisResultDto" - } - } - } - }, - "CounterpartyAnalysisDto": { - "type": "object", - "properties": { - "recipient": { - "type": "object", - "description": "Recipient analysis results mapped by address. Contains recipient interaction history and bridge analysis.type: Record.", - "additionalProperties": { - "$ref": "#/components/schemas/RecipientAnalysisDto" - }, - "example": { - "0x0000000000000000000000000000000000000000": { - "isSafe": true, - "RECIPIENT_INTERACTION": [ - { - "severity": "INFO", - "type": "NEW_RECIPIENT", - "title": "New recipient", - "description": "This is the first time you are interacting with this recipient" - } - ] - } - } - }, - "contract": { - "type": "object", - "description": "Contract analysis results mapped by address. Contains contract verification, interaction history, and delegatecall analysis.type: Record.", - "additionalProperties": { - "$ref": "#/components/schemas/ContractAnalysisDto" - }, - "example": { - "0x0000000000000000000000000000000000000000": { - "CONTRACT_VERIFICATION": [ - { - "severity": "INFO", - "type": "VERIFIED", - "title": "Verified contract", - "description": "This contract has been verified and its source code is available" - } - ] - } - } - }, - "deadlock": { - "type": "object", - "description": "Deadlock analysis results mapped by Safe address. Contains signing deadlock risk findings for owner/threshold management transactions.", - "additionalProperties": { - "$ref": "#/components/schemas/DeadlockAnalysisDto" - }, - "example": { - "0x0000000000000000000000000000000000000000": { - "DEADLOCK": [ - { - "severity": "CRITICAL", - "type": "DEADLOCK_DETECTED", - "title": "Signing deadlock risk detected", - "description": "This change may create a signing cycle between Safes and can permanently lock funds. You will not be allowed to proceed forward." - } - ] - } - } + "transaction", + "conflictType" + ] + }, + "SpaceQueueSafe": { + "type": "object", + "properties": { + "chainId": { + "type": "string" + }, + "safeAddress": { + "type": "string" } }, "required": [ - "recipient", - "contract", - "deadlock" + "chainId", + "safeAddress" ] }, - "ThreatAnalysisRequestDto": { + "SpaceQueueSafeCount": { "type": "object", "properties": { - "data": { - "description": "EIP-712 typed data to analyze for security threats. Contains domain, primaryType, types, and message fields following the EIP-712 standard for structured data signing.", - "allOf": [ - { - "$ref": "#/components/schemas/TypedData" - } - ] + "chainId": { + "type": "string" }, - "walletAddress": { - "type": "string", - "description": "Address of the transaction signer/wallet" + "safeAddress": { + "type": "string" }, - "origin": { - "type": "string", - "description": "Optional origin identifier for the request" + "count": { + "type": "number", + "description": "Transactions of this Safe on this chain that match every filter but `safes`" } }, "required": [ - "data", - "walletAddress" + "chainId", + "safeAddress", + "count" ] }, - "ThreatAnalysisResultDto": { + "SpaceQueueChainCount": { "type": "object", "properties": { - "severity": { - "type": "string", - "description": "Severity level indicating the importance and risk", - "enum": [ - "OK", - "INFO", - "WARN", - "CRITICAL" - ] - }, - "type": { - "type": "string", - "description": "Threat status code", - "enum": [ - "NO_THREAT", - "OWNERSHIP_CHANGE", - "MODULE_CHANGE" - ] - }, - "title": { - "type": "string", - "description": "User-facing title of the finding" + "chainId": { + "type": "string" }, - "description": { - "type": "string", - "description": "Detailed description explaining the finding and its implications" + "count": { + "type": "number", + "description": "Transactions on this chain that match every filter but `chainIds`" + } + }, + "required": [ + "chainId", + "count" + ] + }, + "SpaceQueueSignerCount": { + "type": "object", + "properties": { + "address": { + "type": "string" }, - "error": { - "type": "string", - "description": "Error message for failed analysis" + "count": { + "type": "number", + "description": "Transactions still awaiting this signer that match every filter but `signers`" } }, "required": [ - "severity", - "type", - "title", - "description" + "address", + "count" ] }, - "MasterCopyChangeThreatAnalysisResultDto": { + "SpaceQueueCounts": { "type": "object", "properties": { - "severity": { - "type": "string", - "description": "Severity level indicating the importance and risk", - "enum": [ - "OK", - "INFO", - "WARN", - "CRITICAL" - ] + "total": { + "type": "number", + "description": "Transactions that match every filter but the status ones, the sum of execute, sign, blocked and waiting" }, - "type": { - "type": "string", - "description": "Threat status code", - "enum": [ - "MASTERCOPY_CHANGE" - ] + "execute": { + "type": "number", + "description": "Fully signed and next in line on their Safe and chain" }, - "title": { - "type": "string", - "description": "User-facing title of the finding" + "sign": { + "type": "number", + "description": "Awaiting a signature from one of the caller wallets" }, - "description": { - "type": "string", - "description": "Detailed description explaining the finding and its implications" + "blocked": { + "type": "number", + "description": "Fully signed but behind an earlier nonce" }, - "error": { - "type": "string", - "description": "Error message for failed analysis" + "waiting": { + "type": "number", + "description": "Awaiting signatures from other owners only" }, - "before": { - "type": "string", - "description": "Address of the old master copy/implementation contract" + "conflicting": { + "type": "number", + "description": "Sharing their nonce with another transaction" }, - "after": { - "type": "string", - "description": "Address of the new master copy/implementation contract" + "stale": { + "type": "number", + "description": "Proposed more than 7 days ago" + }, + "safes": { + "description": "Every Safe and chain of the queue read, with how many of its transactions match every filter but `safes`", + "type": "array", + "items": { + "$ref": "#/components/schemas/SpaceQueueSafeCount" + } + }, + "chains": { + "description": "Every chain of the queue read, with how many of its transactions match every filter but `chainIds`", + "type": "array", + "items": { + "$ref": "#/components/schemas/SpaceQueueChainCount" + } + }, + "signers": { + "description": "Every signer a transaction of the queue read still awaits, with how many of those transactions match every filter but `signers`", + "type": "array", + "items": { + "$ref": "#/components/schemas/SpaceQueueSignerCount" + } } }, "required": [ - "severity", - "type", - "title", - "description", - "before", - "after" + "total", + "execute", + "sign", + "blocked", + "waiting", + "conflicting", + "stale", + "safes", + "chains", + "signers" ] }, - "ThreatIssueDto": { + "SpaceQueuedItemPage": { "type": "object", "properties": { - "address": { + "count": { + "type": "number", + "nullable": true, + "description": "Size of the whole queue, which can exceed the items returned when the queue is longer than the pages read" + }, + "next": { "type": "string", - "description": "Address involved in the issue, if applicable" + "nullable": true, + "description": "Always null: the queue is returned in one response" }, - "description": { + "previous": { "type": "string", - "description": "Issue description" + "nullable": true, + "description": "Always null: the queue is returned in one response" + }, + "results": { + "type": "object", + "additionalProperties": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/ConflictHeaderQueuedItem" + }, + { + "$ref": "#/components/schemas/LabelQueuedItem" + }, + { + "$ref": "#/components/schemas/TransactionQueuedItem" + } + ] + } + } + }, + "example": { + "{safeAddress}": { + "{chainId}": [] + } + }, + "description": "Queued items, keyed by Safe address and then by chain ID, each list in nonce order." + }, + "unavailableSafes": { + "description": "Space Safes whose queue is missing from this response because their Safe information could not be loaded or the Space exceeds the Safes one request can cover.", + "type": "array", + "items": { + "$ref": "#/components/schemas/SpaceQueueSafe" + } + }, + "counts": { + "description": "Faceted counts of the queue read: each applies every filter but its own. The status counts skip the status filters (`status`, `conflicting`, `stale`); `safes`, `chains` and `signers` skip `safes`, `chainIds` and `signers`. The search narrows every count.", + "allOf": [ + { + "$ref": "#/components/schemas/SpaceQueueCounts" + } + ] } }, "required": [ - "description" + "count", + "next", + "previous", + "results", + "unavailableSafes", + "counts" ] }, - "MaliciousOrModerateThreatAnalysisResultDto": { + "PolicyConfigurationDto": { "type": "object", "properties": { - "severity": { + "target": { "type": "string", - "description": "Severity level indicating the importance and risk", - "enum": [ - "OK", - "INFO", - "WARN", - "CRITICAL" - ] + "description": "Contract the guarded call targets" }, - "type": { + "selector": { "type": "string", - "description": "Threat status code", + "description": "4-byte function selector", + "example": "0xa9059cbb" + }, + "operation": { + "type": "number", "enum": [ - "MALICIOUS", - "MODERATE" - ] + 0, + 1 + ], + "description": "0 = CALL, 1 = DELEGATECALL" }, - "title": { + "policy": { "type": "string", - "description": "User-facing title of the finding" + "description": "Policy contract to bind. The zero address removes the policy of this access." }, - "description": { + "data": { "type": "string", - "description": "Detailed description explaining the finding and its implications" - }, - "error": { + "description": "Policy payload, abi-encoded as passed to the guard. At most 64 KiB (65,536 bytes)." + } + }, + "required": [ + "target", + "selector", + "operation", + "policy", + "data" + ] + }, + "CreatePolicyConfigurationRequestDto": { + "type": "object", + "properties": { + "root": { "type": "string", - "description": "Error message for failed analysis" + "description": "keccak256(abi.encode(Configuration[])), as requested on-chain" }, - "issues": { - "type": "object", - "description": "A partial record of specific issues identified during threat analysis, grouped by severity.Record