List roles
/rolescurl -X GET https://api.tst.au.apgpay.dev/roles \
-H "Authorization: Bearer $API_KEY"Return a page of roles. Supply page for offset pagination or startingAfter for cursor pagination, and q to search. GET /filter-catalogues/roles lists the filters this caller can use. A cursor continues only the walk that issued it: sent with different filters, q or sort, it is refused with 400.
Permissions
roles:queryRequires the `query` action on `roles` for the supplied runtime context
Query parameters
qstringSearch. Matches a role id or the name. An id, an email address, a phone number and any value listed as matched exactly match exactly; any other term matches without regard to case from the start of a value (or of any word in it, beside a longer word of the term), or anywhere in it from three characters, every word of it somewhere; a term that matches nothing so is read again with typos tolerated. Closest matches come first unless sort is given.
pageinteger (int32)Offset pagination: 1-based page number. Mutually exclusive with the cursor parameters.
startingAfterstringCursor pagination, moving forward: the id of the last item on the current page. Mutually exclusive with page.
endingBeforestringCursor pagination, moving backward: the id of the first item on the current page. Mutually exclusive with page.
limitinteger (int32)Maximum items per page.
sortarray of RoleSortFields to sort by, comma-delimited, in priority order. Prefix a field with - for descending.
columnsarray of RoleColumnColumns to include, in order, when asking for text/csv. Omit for all of them. Sending it with application/json is a 400.
namestringFilter by role name.
roleTypeone of RoleType, array of RoleTypeOnly roles whose kind is one of these. Repeat the parameter to give several.
Responses
The response is a tagged shape: type is always "RolePageAttributes". Switch on it; subtypes can be added, and a client that already reads it will not break.
typetype = "RolePageAttributes"typeA role the platform defines, carrying its own grants and available everywhere.
roleIdRoleIdrequiredIdentifier of a role.
Example role_9f2Kd8QpLzXw
namestringrequiredExample Ada Lovelace
The grants this role carries.
typeenumrequiredRoleGrantAttributesresourcePermissionResourcerequiredThe resource this grant is over.
BlockedCardCustomerDelegatesDisputesEnterprisesFxRatesLoanFacilitiesLoanProductsLoanTransactionsLoanMasterAgreementsLoans+52 moreShow fewer
LoanStatements, CreditCards, Files, Queues, Reports, Simulations, Marketplaces, MarketplaceUsers, Merchants, MerchantCustomers, Orders, CustomerPaymentSources, TemporaryPaymentSources, PaymentTokens, PayPlanOffers, PayCards, PayPlans, PayToAgreements, Refunds, MerchantServiceTokens, MarketplaceServiceTokens, EnterpriseServiceTokens, SourceVerifications, SystemJournals, SystemJournalEntries, SystemLedgers, SystemLedgerEntries, Transactions, IssuerTransactions, IssuerTransactionDiscrepancies, WebhookMerchantSubscriptions, WebhookMarketplaceSubscriptions, WebhookSubscriptions, Sessions, ServiceTokens, ReferenceData, Users, Roles, OidcIdps, ReportsAcquiring, ReportsLending, ReportsIssuing, ReportsCustomers, ReportsOperations, ReportsOversight, Organisations, Persons, Suppliers, Rules, MerchantStatementPasswords, MerchantTravelData, Unknown
actionsarray of PermissionActionThe actions this grant allows on the resource.
CreateReadUpdateDeleteReadPiiReadAllCreateBillingPaymentSourceReadBillingPaymentSourceUpdateBillingPaymentSourceDeleteBillingPaymentSource+38 moreShow fewer
CreateFinancials, ReadFinancials, SearchFinancials, UpdateFinancials, DeleteFinancials, CreateKyb, ReadKyb, UpdateKyb, DeleteKyb, CreatePaymentProfiles, ReadPaymentProfiles, UpdatePaymentProfiles, DeletePaymentProfiles, CreatePermissions, ReadPermissions, UpdatePermissions, DeletePermissions, CreateState, ReadState, UpdateState, DeleteState, Activate, ActivatePaymentProfile, Apply, CreateUatp, Impersonate, Link, Orchestrate, Pay, Search, Simulate, SpecifySurcharge, Transfer, Upsert, UpsertMinimal, UpsertPlugin, Verify, Unknown
createdAtstring (date-time)requiredExample 2026-08-19T04:21:07Z
updatedAtstring (date-time)requiredExample 2026-08-19T04:21:07Z
A role a domain defines, carrying its own grants.
roleIdRoleIdrequiredIdentifier of a role.
Example role_9f2Kd8QpLzXw
namestringrequiredExample Ada Lovelace
The grants this role carries.
typeenumrequiredRoleGrantAttributesresourcePermissionResourcerequiredThe resource this grant is over.
BlockedCardCustomerDelegatesDisputesEnterprisesFxRatesLoanFacilitiesLoanProductsLoanTransactionsLoanMasterAgreementsLoans+52 moreShow fewer
LoanStatements, CreditCards, Files, Queues, Reports, Simulations, Marketplaces, MarketplaceUsers, Merchants, MerchantCustomers, Orders, CustomerPaymentSources, TemporaryPaymentSources, PaymentTokens, PayPlanOffers, PayCards, PayPlans, PayToAgreements, Refunds, MerchantServiceTokens, MarketplaceServiceTokens, EnterpriseServiceTokens, SourceVerifications, SystemJournals, SystemJournalEntries, SystemLedgers, SystemLedgerEntries, Transactions, IssuerTransactions, IssuerTransactionDiscrepancies, WebhookMerchantSubscriptions, WebhookMarketplaceSubscriptions, WebhookSubscriptions, Sessions, ServiceTokens, ReferenceData, Users, Roles, OidcIdps, ReportsAcquiring, ReportsLending, ReportsIssuing, ReportsCustomers, ReportsOperations, ReportsOversight, Organisations, Persons, Suppliers, Rules, MerchantStatementPasswords, MerchantTravelData, Unknown
actionsarray of PermissionActionThe actions this grant allows on the resource.
CreateReadUpdateDeleteReadPiiReadAllCreateBillingPaymentSourceReadBillingPaymentSourceUpdateBillingPaymentSourceDeleteBillingPaymentSource+38 moreShow fewer
CreateFinancials, ReadFinancials, SearchFinancials, UpdateFinancials, DeleteFinancials, CreateKyb, ReadKyb, UpdateKyb, DeleteKyb, CreatePaymentProfiles, ReadPaymentProfiles, UpdatePaymentProfiles, DeletePaymentProfiles, CreatePermissions, ReadPermissions, UpdatePermissions, DeletePermissions, CreateState, ReadState, UpdateState, DeleteState, Activate, ActivatePaymentProfile, Apply, CreateUatp, Impersonate, Link, Orchestrate, Pay, Search, Simulate, SpecifySurcharge, Transfer, Upsert, UpsertMinimal, UpsertPlugin, Verify, Unknown
The domain that owns this role.
typeAn unauthenticated caller, restricted to what the wrapped domain permits.
typeOne customer.
customerIdCustIdrequiredIdentifier of a customer.
Example cust_9f2Kd8QpLzXw
A delegate acting for one customer. Scoped by both, because a delegate can act for several.
delegateIdCustdIdrequiredIdentifier of a customer delegate.
Example custd_9f2Kd8QpLzXw
forCustomerIdCustIdrequiredIdentifier of a customer.
Example cust_9f2Kd8QpLzXw
loanAccessarray of LoanIdLoans this delegate may act on for this customer; absent = unrestricted.
Example loan_9f2Kd8QpLzXw
One enterprise.
enterpriseIdEntIdrequiredIdentifier of an enterprise.
Example ent_9f2Kd8QpLzXw
One marketplace.
marketplaceIdMktpIdrequiredIdentifier of a marketplace.
Example mktp_9f2Kd8QpLzXw
One merchant.
merchantIdMchtIdrequiredIdentifier of a merchant.
Example mcht_9f2Kd8QpLzXw
The whole platform. Held by platform operators.
The whole platform. Held by platform operators.
One customer.
customerIdCustIdrequiredIdentifier of a customer.
Example cust_9f2Kd8QpLzXw
A delegate acting for one customer. Scoped by both, because a delegate can act for several.
delegateIdCustdIdrequiredIdentifier of a customer delegate.
Example custd_9f2Kd8QpLzXw
forCustomerIdCustIdrequiredIdentifier of a customer.
Example cust_9f2Kd8QpLzXw
loanAccessarray of LoanIdLoans this delegate may act on for this customer; absent = unrestricted.
Example loan_9f2Kd8QpLzXw
One enterprise.
enterpriseIdEntIdrequiredIdentifier of an enterprise.
Example ent_9f2Kd8QpLzXw
One marketplace.
marketplaceIdMktpIdrequiredIdentifier of a marketplace.
Example mktp_9f2Kd8QpLzXw
One merchant.
merchantIdMchtIdrequiredIdentifier of a merchant.
Example mcht_9f2Kd8QpLzXw
A domain that no longer resolves, the party it named is gone.
A domain that no longer resolves, the party it named is gone.
The whole platform. Held by platform operators.
The whole platform. Held by platform operators.
createdAtstring (date-time)requiredExample 2026-08-19T04:21:07Z
updatedAtstring (date-time)requiredExample 2026-08-19T04:21:07Z
A role that is the union of other roles.
roleIdRoleIdrequiredIdentifier of a role.
Example role_9f2Kd8QpLzXw
namestringrequiredExample Ada Lovelace
groupedRolesarray of RoleIdThe roles this one groups. Their grants are what it permits; read them to resolve it.
Example role_9f2Kd8QpLzXw
The domain that owns this role.
typeAn unauthenticated caller, restricted to what the wrapped domain permits.
typeOne customer.
customerIdCustIdrequiredIdentifier of a customer.
Example cust_9f2Kd8QpLzXw
A delegate acting for one customer. Scoped by both, because a delegate can act for several.
delegateIdCustdIdrequiredIdentifier of a customer delegate.
Example custd_9f2Kd8QpLzXw
forCustomerIdCustIdrequiredIdentifier of a customer.
Example cust_9f2Kd8QpLzXw
loanAccessarray of LoanIdLoans this delegate may act on for this customer; absent = unrestricted.
Example loan_9f2Kd8QpLzXw
One enterprise.
enterpriseIdEntIdrequiredIdentifier of an enterprise.
Example ent_9f2Kd8QpLzXw
One marketplace.
marketplaceIdMktpIdrequiredIdentifier of a marketplace.
Example mktp_9f2Kd8QpLzXw
One merchant.
merchantIdMchtIdrequiredIdentifier of a merchant.
Example mcht_9f2Kd8QpLzXw
The whole platform. Held by platform operators.
The whole platform. Held by platform operators.
One customer.
customerIdCustIdrequiredIdentifier of a customer.
Example cust_9f2Kd8QpLzXw
A delegate acting for one customer. Scoped by both, because a delegate can act for several.
delegateIdCustdIdrequiredIdentifier of a customer delegate.
Example custd_9f2Kd8QpLzXw
forCustomerIdCustIdrequiredIdentifier of a customer.
Example cust_9f2Kd8QpLzXw
loanAccessarray of LoanIdLoans this delegate may act on for this customer; absent = unrestricted.
Example loan_9f2Kd8QpLzXw
One enterprise.
enterpriseIdEntIdrequiredIdentifier of an enterprise.
Example ent_9f2Kd8QpLzXw
One marketplace.
marketplaceIdMktpIdrequiredIdentifier of a marketplace.
Example mktp_9f2Kd8QpLzXw
One merchant.
merchantIdMchtIdrequiredIdentifier of a merchant.
Example mcht_9f2Kd8QpLzXw
A domain that no longer resolves, the party it named is gone.
A domain that no longer resolves, the party it named is gone.
The whole platform. Held by platform operators.
The whole platform. Held by platform operators.
createdAtstring (date-time)requiredExample 2026-08-19T04:21:07Z
updatedAtstring (date-time)requiredExample 2026-08-19T04:21:07Z
hasMorebooleanrequiredWhether further items exist after this page.
Example true
nextStartingAfterstringId to pass as startingAfter to fetch the next page. Present in cursor mode only.
totalCountinteger (int64)Total items matching the query.
Example 42
pageinteger (int32)The 1-based page returned. Present in offset mode only.
Example 1250
totalPagesinteger (int32)Total pages available. Present in offset mode only.
Example 1250
{
"type": "RolePageAttributes",
"data": [
{
"type": "RoleViewBuiltIn",
"roleId": "role_9f2Kd8QpLzXw",
"name": "Ada Lovelace",
"grants": [
{
"type": "RoleGrantAttributes",
"resource": "BlockedCard",
"actions": [
"Create"
]
}
],
"createdAt": "2026-08-19T04:21:07Z",
"updatedAt": "2026-08-19T04:21:07Z"
}
],
"hasMore": true,
"nextStartingAfter": "string",
"totalCount": 42,
"page": 1250,
"totalPages": 1250
}Error responses
statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}statusCodeinteger (int32)requiredHTTP status code for this error
errorCodestringrequiredAn APG Pay code providing a brief explanation of the underlying error. Use this if you wish to provide custom behaviour based on the error type.
messagestringrequiredHuman readable description of the error
tracerstringAn unique identifier for the request. Provide this to the support team if you wish to query a particular error.
detailstringOptional additional details for the error.
errorTypeDescriptionstringA description of the category of errors for the given statusCode.
metadataobjectOptional key value list of metadata
{
"statusCode": 100,
"errorCode": "string",
"message": "string",
"tracer": "string",
"detail": "string",
"errorTypeDescription": "string"
}