partners
Requires at least one of the permissions customers:customer:list, customers:customer:read, payments:collection:create, payments:invoice:create, products:discount:update, purchase:debit_note:create, purchase:grn:create, purchase:payment:create, purchase:purchase_invoice:create, purchase:purchase_order:create, sales:credit_note:create, sales:quote:create, sales:sales_order:create, suppliers:supplier:list or suppliers:supplier:read.
Lists the partners the signed-in user may see, with an optional filter and sort. Pass skip and take to read one page, and use partnersCount for the total. Customers are listed for callers with a customer read grant or a grant to raise a customer document; suppliers for callers with a supplier read grant or a grant to raise a purchase document.
Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.
Example:
- GraphQL
- cURL
query Partners {
partners {
id
code
registrationNumber
name
displayName
legalName
addresses {
id
postalCode
contactName
type
createdAt
city
}
}
}
curl -X POST "https://<api-host>/graphql" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
--data @- <<'EOF'
{
"query": "query Partners {\n partners {\n id\n code\n registrationNumber\n name\n displayName\n legalName\n addresses {\n id\n postalCode\n contactName\n type\n createdAt\n city\n }\n }\n}"
}
EOF
Response:
{
"data": {
"partners": [
{
"id": "id",
"code": "string",
"registrationNumber": "string",
"name": "string",
"displayName": "string",
"legalName": "string",
"addresses": [
{
"id": "id",
"postalCode": "string",
"contactName": "string",
"type": "string",
"createdAt": "2025-01-15T00:00:00Z",
"city": "string"
}
]
}
]
}
}
partners(
filter: PartnerFilterInput
skip: Int
sort: PartnerSortInput
take: Int
): [Partner!]!
Arguments
partners.filter ● PartnerFilterInput input
Narrows the partners returned.
partners.skip ● Int scalar
The number of partners to skip.
partners.sort ● PartnerSortInput input
The order of the results.
partners.take ● Int scalar
The maximum number of partners to return. Leave out skip and take to get the whole set.
Type
Partner object
A partner: the one master record for customers and vendors, with its roles, addresses, contacts and account details.