For the complete documentation index, see llms.txt. This page is also available as Markdown.

Search customers

The query field searches on: firstName, lastName, city, postalCode, companyName, mobile, email and vatNumber. If scope is not set, customer scope is used. When mobile, email or vatNumber is specified, the according field is not searched by the query field value.

post
/tenants/{tenantUid}/customers/search
Authorizations
AuthorizationstringRequired

Access token recevied after user login with a deviceToken

Path parameters
tenantUidstringRequired

Reference to a tenant.

Pattern: ^[A-Za-z0-9-_]+
Query parameters
pageNumberintegerOptional

Reference to a specific page in a result set.

pageSizeintegerOptional

The number of items per page in a result set.

sortBystringOptional

Defines which field the resource list is sorted by.

sortDirectionstring · enumOptional
ENUMDescription
ASCSort in ascending order
DESCSort in descending order
Possible values:
Body
exactMatchbooleanOptional
querystringOptional
mobilestringOptional
emailstringOptional
vatNumberstringOptional
storeUidstringOptionalPattern: ^[A-Za-z0-9-_]+
customerParentUidstringOptionalPattern: ^[A-Za-z0-9-_]+
createdAtstring · date-timeOptional
customerGroupUidsstring[]Optional

Match customers who are members of any of these customer groups.

hasMobilebooleanOptional

Filter on whether the customer has a mobile number at all, as opposed to matching a specific one. true matches customers whose own mobile is set and non-empty; false matches those without one. Mobile numbers on contact rows are not considered. Omitted does not filter.

hasEmailbooleanOptional

Filter on whether the customer has an email address at all, as opposed to matching a specific one. true matches customers whose own email is set and non-empty; false matches those without one. Email addresses on contact rows are not considered. Omitted does not filter.

Responses
200

CustomerListResponse

application/json
post/tenants/{tenantUid}/customers/search
POST /v2/tenants/{tenantUid}/customers/search HTTP/1.1
Host: api.flowretail.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 564

{
  "exactMatch": true,
  "query": "text",
  "mobile": "text",
  "email": "text",
  "scope": [
    "CUSTOMER"
  ],
  "customerTypes": [
    "COMPANY"
  ],
  "vatNumber": "text",
  "storeUid": "text",
  "customerParentUid": "text",
  "createdAt": "2026-01-01T00:00:00.000Z",
  "customerGroupUids": [
    "text"
  ],
  "consents": [
    {
      "consentUid": "text",
      "granted": true
    }
  ],
  "purchaseHistory": {
    "productUids": [
      "text"
    ],
    "productGroupUids": [
      "text"
    ],
    "categoryUids": [
      "text"
    ],
    "activity": {
      "mode": "NEVER",
      "dateBasis": "ORDER_DATE",
      "from": "2026-01-01T00:00:00.000Z",
      "to": "2026-01-01T00:00:00.000Z",
      "storeUids": [
        "text"
      ]
    }
  },
  "hasMobile": true,
  "hasEmail": true
}
200

CustomerListResponse

{
  "items": [
    {
      "address": "text",
      "city": "text",
      "companyName": "text",
      "countryCode": "text",
      "createdAt": "2026-01-01T00:00:00.000Z",
      "customerUid": "text",
      "customerParentUid": "text",
      "customerType": "COMPANY",
      "email": "text",
      "externalId": "text",
      "customerNumber": "text",
      "firstname": "text",
      "lastModifiedAt": "2026-01-01T00:00:00.000Z",
      "lastname": "text",
      "mobile": "text",
      "postalCode": "text",
      "pricelistUid": "text",
      "vatNumber": "text",
      "origin": "text",
      "addresses": [
        {
          "address": "text",
          "city": "text",
          "companyName": "text",
          "firstname": "text",
          "lastname": "text",
          "countryCode": "text",
          "email": "text",
          "phone": "text",
          "postalCode": "text",
          "type": "DELIVERY_ADDRESS",
          "customerAddressUid": "text",
          "displayName": "text"
        }
      ],
      "contacts": [
        {
          "firstname": "text",
          "lastname": "text",
          "email": "text",
          "mobile": "text",
          "address": "text",
          "postalCode": "text",
          "city": "text",
          "createdAt": "2026-01-01T00:00:00.000Z",
          "lastModifiedAt": "2026-01-01T00:00:00.000Z",
          "customerContactUid": "text",
          "extensions": [
            {
              "extensionCode": "TWO_INVOICE",
              "organizationUid": "text"
            }
          ],
          "displayName": "text",
          "role": "ADMIN"
        }
      ],
      "extensions": [
        {
          "extensionCode": "TWO_INVOICE",
          "organizationUid": "text"
        }
      ],
      "consents": [
        {
          "consentUid": "text",
          "name": "text",
          "status": true,
          "source": "text",
          "createdAt": "2026-01-01T00:00:00.000Z"
        }
      ],
      "loyaltyId": "text",
      "displayName": "text",
      "credit": {
        "limit": 1,
        "balance": 1
      },
      "paymentTerms": 1,
      "internalNote": "text",
      "accountManager": {
        "tenantUserUid": "text",
        "displayName": "text",
        "userCode": "text"
      },
      "ehf": {
        "enabled": true,
        "address": "text"
      },
      "customerGroupUids": [
        "text"
      ],
      "defaultStore": {
        "name": "text",
        "storeUid": "text"
      },
      "representedStore": {
        "name": "text",
        "storeUid": "text"
      },
      "relevance": 1
    }
  ],
  "paging": {
    "pageNumber": 1,
    "pageSize": 1,
    "totalCount": 1
  }
}

Last updated

Was this helpful?