Merchants & Providers
These queries return information about the authenticated merchant and the transaction providers configured for that merchant account.
merchantApi
Return the authenticated merchant's profile. Useful for verifying credentials and retrieving the merchant's public ID.
query GetMerchant {
merchantApi {
id
name
publicId
createdAt
updatedAt
}
}
Arguments
None. The merchant is determined from the accrupay-api-secret header.
Return shape
| Field | Type | Description |
|---|---|---|
id | String | AccruPay merchant UUID |
name | String | Merchant display name |
publicId | String | Public-facing merchant identifier — used by the React SDK to initialize the checkout component |
createdAt | DateTimeISO | Account creation timestamp |
updatedAt | DateTimeISO | Last update timestamp |
merchantApiTransactionProviders
List all transaction providers configured for the authenticated merchant.
query ListProviders($status: MERCHANT_TRANSACTION_PROVIDER_STATUS, $take: Int) {
merchantApiTransactionProviders(status: $status, take: $take) {
edges {
node {
id
provider
providerCode
status
createdAt
}
cursor
}
pageInfo {
hasNextPage
endCursor
}
totalCount
}
}
Arguments
| Argument | Type | Description |
|---|---|---|
id | String | Filter by provider record UUID |
provider | TRANSACTION_PROVIDER | Filter by provider enum |
status | MERCHANT_TRANSACTION_PROVIDER_STATUS | Filter by ENABLED / DISABLED |
take / skip | Int | Offset pagination |
first / after, last / before | Int / ConnectionCursor | Cursor pagination |
sorting | [SortingFieldSchema!] | Sort order |
Return shape — MerchantTransactionProviderPaginationConnection (edges { node }, pageInfo, totalCount). Each node:
| Field | Type | Description |
|---|---|---|
id | ID | AccruPay provider record UUID — use this as merchantTransactionProviderId in mutations |
provider | TRANSACTION_PROVIDER | Provider enum identifier (e.g. NUVEI, STRIPE) |
providerCode | String | Provider's own reference code |
status | MERCHANT_TRANSACTION_PROVIDER_STATUS | ENABLED or DISABLED |
merchantId | String | Owning merchant ID |
applicationId | String | null | Provider application ID, when applicable |
createdAt | DateTimeISO | Provider record creation timestamp |
updatedAt | DateTimeISO | Last update timestamp |
merchantApiTransactionProvider
Fetch a single transaction provider record by ID.
query GetProvider($merchantTransactionProviderId: String!) {
merchantApiTransactionProvider(
merchantTransactionProviderId: $merchantTransactionProviderId
) {
id
provider
providerCode
status
createdAt
updatedAt
}
}
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
merchantTransactionProviderId | String | Yes | AccruPay provider record UUID |
Return shape
| Field | Type | Description |
|---|---|---|
id | ID | Provider record UUID |
provider | TRANSACTION_PROVIDER | Provider enum |
providerCode | String | Provider's own reference code |
status | MERCHANT_TRANSACTION_PROVIDER_STATUS | ENABLED or DISABLED |
merchantId | String | Owning merchant ID |
applicationId | String | null | Provider application ID, when applicable |
createdAt | DateTimeISO | Creation timestamp |
updatedAt | DateTimeISO | Last update timestamp |
Provider IDs vs provider enums
Most mutations accept either merchantTransactionProviderId or transactionProvider to specify which provider to route through.
| Option | When to use |
|---|---|
merchantTransactionProviderId | You have multiple providers of the same type, or you want to be explicit about which configured record to use |
transactionProvider | You have exactly one provider of that type; AccruPay resolves the record automatically |
If both are provided, they are combined (AND): they must resolve to the same connected provider account, otherwise the request fails with a provider-not-found error. If neither is provided, the mutation fails with a provider-selection AppError key in extensions.code. See Errors.