Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12,418 changes: 7,851 additions & 4,567 deletions packages/store/scripts/api-schema/schema.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion packages/store/src/gateway/AUTO_GENERATED/.schema-hash
Original file line number Diff line number Diff line change
@@ -1 +1 @@
e9984df7d8acc32efa5370bd62918903c1a9aedda334828d00ef55ff0e922556
015c768c74175ce15472b5952479837324ef422f0683b0cac5682a4c5d8c07f7
3 changes: 3 additions & 0 deletions packages/store/src/gateway/AUTO_GENERATED/chains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,11 @@ export type Theme = {
export type Relayer = {
type: ('GTF' | 'RELAY_FEE' | 'DAILY_LIMIT' | 'NO_FEE_CAMPAIGN') | null
safeCreationSponsored: boolean
/** Use gasPaymentOptions instead. */
safeTransactionSponsored: boolean
enableTenderlySimulationBeforeRelay: boolean
/** Who may pay for a relayed transaction on this chain. */
gasPaymentOptions: ('FREE_DAILY_LIMIT' | 'SUBSCRIPTION' | 'PAY_FROM_SAFE' | 'NO_FEE_CAMPAIGN')[]
}
export type Chain = {
chainId: string
Expand Down
93 changes: 93 additions & 0 deletions packages/store/src/gateway/AUTO_GENERATED/delegates.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,43 @@ const injectedRtkApi = api
}),
invalidatesTags: ['delegates'],
}),
delegatesGetDelegatesV3: build.query<DelegatesGetDelegatesV3ApiResponse, DelegatesGetDelegatesV3ApiArg>({
query: (queryArg) => ({
url: `/v3/chains/${queryArg.chainId}/delegates`,
params: {
cursor: queryArg.cursor,
label: queryArg.label,
delegator: queryArg.delegator,
delegate: queryArg.delegate,
safe: queryArg.safe,
},
}),
providesTags: ['delegates'],
}),
delegatesPostDelegateV3: build.mutation<DelegatesPostDelegateV3ApiResponse, DelegatesPostDelegateV3ApiArg>({
query: (queryArg) => ({
url: `/v3/chains/${queryArg.chainId}/delegates`,
method: 'POST',
body: queryArg.createDelegateDto,
}),
invalidatesTags: ['delegates'],
}),
delegatesUpdateDelegateV3: build.mutation<DelegatesUpdateDelegateV3ApiResponse, DelegatesUpdateDelegateV3ApiArg>({
query: (queryArg) => ({
url: `/v3/chains/${queryArg.chainId}/delegates`,
method: 'PATCH',
body: queryArg.updateDelegateV3Dto,
}),
invalidatesTags: ['delegates'],
}),
delegatesDeleteDelegateV3: build.mutation<DelegatesDeleteDelegateV3ApiResponse, DelegatesDeleteDelegateV3ApiArg>({
query: (queryArg) => ({
url: `/v3/chains/${queryArg.chainId}/delegates/${queryArg.delegateAddress}`,
method: 'DELETE',
body: queryArg.deleteDelegateV3Dto,
}),
invalidatesTags: ['delegates'],
}),
}),
overrideExisting: false,
})
Expand Down Expand Up @@ -132,6 +169,45 @@ export type DelegatesDeleteDelegateV2ApiArg = {
/** Signature and data proving authorization to delete the delegate */
deleteDelegateV2Dto: DeleteDelegateV2Dto
}
export type DelegatesGetDelegatesV3ApiResponse =
/** status 200 Paginated list of delegates retrieved successfully */ DelegatePage
export type DelegatesGetDelegatesV3ApiArg = {
/** Chain ID where delegates are registered */
chainId: string
/** Pagination cursor for retrieving the next set of results */
cursor?: string
/** Filter by delegate label or name */
label?: string
/** Filter by delegator address (0x prefixed hex string) */
delegator?: string
/** Filter by delegate address (0x prefixed hex string) */
delegate?: string
/** Filter by Safe address (0x prefixed hex string) */
safe?: string
}
export type DelegatesPostDelegateV3ApiResponse = unknown
export type DelegatesPostDelegateV3ApiArg = {
/** Chain ID where the delegate will be registered */
chainId: string
/** Delegate creation data including Safe address, delegate address, label, and authorization signature */
createDelegateDto: CreateDelegateDto
}
export type DelegatesUpdateDelegateV3ApiResponse = unknown
export type DelegatesUpdateDelegateV3ApiArg = {
/** Chain ID where the delegate is registered */
chainId: string
/** Delegate update data including Safe address, delegate address, delegator, label, and authorization signature */
updateDelegateV3Dto: UpdateDelegateV3Dto
}
export type DelegatesDeleteDelegateV3ApiResponse = unknown
export type DelegatesDeleteDelegateV3ApiArg = {
/** Chain ID where the delegate is registered */
chainId: string
/** Delegate address to remove (0x prefixed hex string) */
delegateAddress: string
/** Signature and data proving authorization to delete the delegate */
deleteDelegateV3Dto: DeleteDelegateV3Dto
}
export type Delegate = {
safe?: string | null
delegate: string
Expand Down Expand Up @@ -161,6 +237,18 @@ export type DeleteDelegateV2Dto = {
safe?: string | null
signature: string
}
export type UpdateDelegateV3Dto = {
safe?: string | null
delegate: string
delegator: string
signature: string
label: string
}
export type DeleteDelegateV3Dto = {
delegator?: string | null
safe?: string | null
signature: string
}
export const {
useDelegatesGetDelegatesV1Query,
useLazyDelegatesGetDelegatesV1Query,
Expand All @@ -170,4 +258,9 @@ export const {
useLazyDelegatesGetDelegatesV2Query,
useDelegatesPostDelegateV2Mutation,
useDelegatesDeleteDelegateV2Mutation,
useDelegatesGetDelegatesV3Query,
useLazyDelegatesGetDelegatesV3Query,
useDelegatesPostDelegateV3Mutation,
useDelegatesUpdateDelegateV3Mutation,
useDelegatesDeleteDelegateV3Mutation,
} = injectedRtkApi
31 changes: 21 additions & 10 deletions packages/store/src/gateway/AUTO_GENERATED/messages.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ export type TypedDataDomain = {
salt?: string
verifyingContract?: string
version?: string
safe?: string
}
export type TypedDataParameter = {
name: string
Expand All @@ -110,35 +111,45 @@ export type MessageConfirmation = {
owner: AddressInfo
signature: string
}
export type SafeAppInfo = {
id: number
name: string
url: string
logoUri?: string | null
}
export type Message = {
messageHash: string
status: 'NEEDS_CONFIRMATION' | 'CONFIRMED'
logoUri?: string | null
name?: string | null
logoUri: string | null
name: string | null
message: string | TypedData

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 IMPORTANT: Breaking Type Contract Change for proposedBy

Failure Trace:

  1. The diff changes proposedBy in Message and MessageItem from AddressInfo (required, non-null) to AddressInfo | null (required, nullable).
    2. Existing client code (outside this diff) likely contains patterns like message.proposedBy.address or message.proposedBy.name based on the previous type definition.
    3. If the API now returns null for proposedBy (which is now a valid state per the new type), the client code will throw a TypeError: Cannot read properties of null (reading 'address') at runtime.
    4. Even if the API never returns null, the type change forces all consumers to add null checks, indicating a semantic shift in the data contract that breaks existing type-safe code.

Actionable Fix:
This is a generated file. The fix must be applied to the source of truth (the API schema or the code generator configuration) to ensure backward compatibility or to coordinate a breaking release. If this is an intentional breaking change, ensure all consumers are updated to handle null for proposedBy. If not, revert the schema change to keep proposedBy as AddressInfo (non-nullable) or ensure the generator marks it as optional AddressInfo | undefined if the field can be absent, rather than nullable AddressInfo | null if the field is always present but can be null.

creationTimestamp: number
modifiedTimestamp: number
confirmationsSubmitted: number
confirmationsRequired: number
proposedBy: AddressInfo
proposedBy: AddressInfo | null
confirmations: MessageConfirmation[]
preparedSignature?: string | null
origin?: string | null
preparedSignature: string | null
origin: string | null
safeAppInfo: SafeAppInfo | null
safeAppId: number | null
}
export type MessageItem = {
messageHash: string
status: 'NEEDS_CONFIRMATION' | 'CONFIRMED'
logoUri?: string | null
name?: string | null
logoUri: string | null
name: string | null
message: string | TypedData
creationTimestamp: number
modifiedTimestamp: number
confirmationsSubmitted: number
confirmationsRequired: number
proposedBy: AddressInfo
proposedBy: AddressInfo | null
confirmations: MessageConfirmation[]
preparedSignature?: string | null
origin?: string | null
preparedSignature: string | null
origin: string | null
safeAppInfo: SafeAppInfo | null
safeAppId: number | null
type: 'MESSAGE'
}
export type DateLabel = {
Expand Down
14 changes: 13 additions & 1 deletion packages/store/src/gateway/AUTO_GENERATED/relay.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,24 @@ export type RelayGetRelaysRemainingV1ApiArg = {
chainId: string
/** Safe contract address (0x prefixed hex string) */
safeAddress: string
/** 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. */
/** Safe transaction hash (0x prefixed hex string). Ignored; kept so existing clients do not break. */
safeTxHash?: string
}
export type Relay = {
taskId: string
}
export type GasPaymentOptionUnavailableResponse = {
code: 'GAS_PAYMENT_OPTION_UNAVAILABLE'
/** Human-readable description of the error. Informational only; do not parse. */
message: string
statusCode: number
/** The gas payment option the request needed. */
requested: 'FREE_DAILY_LIMIT' | 'SUBSCRIPTION' | 'PAY_FROM_SAFE' | 'NO_FEE_CAMPAIGN'
/** NOT_LISTED: the chain does not list the option. NO_RELAYER: the chain has no relayer. NOT_A_WORKSPACE_SAFE: the Safe is not one the workspace holds. REFUNDING_TRANSACTION: the transaction would refund gas (`gasPrice` > 0). */
reason: 'NOT_LISTED' | 'NO_RELAYER' | 'NOT_A_WORKSPACE_SAFE' | 'REFUNDING_TRANSACTION'
/** The options the chain lists; empty without a relayer. */
available: ('FREE_DAILY_LIMIT' | 'SUBSCRIPTION' | 'PAY_FROM_SAFE' | 'NO_FEE_CAMPAIGN')[]
}
export type RelayErrorResponse = {
/** Stable identifier of the error condition. The frontend MUST branch on this value (not on `message`, which is informational and may change). */
code: 'SIMULATION_FAILED' | 'INDETERMINATE_SIMULATION'
Expand Down
1 change: 1 addition & 0 deletions packages/store/src/gateway/AUTO_GENERATED/safe-shield.ts
Original file line number Diff line number Diff line change
Expand Up @@ -353,6 +353,7 @@ export type TypedDataDomain = {
salt?: string
verifyingContract?: string
version?: string
safe?: string
}
export type TypedDataParameter = {
name: string
Expand Down
Loading
Loading