Development
  • Guides
  • API Reference
  • API Explorer
  • SDKs
  • Sample apps
  • System status
Support
  • Developer forums
  • Developer blog
  • YouTube
  • X
More
  • Square Home
  • Square Developer
  • App Marketplace
  • Partner with Square
  • Solutions Partner Program
  • Pricing
  • Sales

© 2026 Square, Inc.

  • Developer terms of service
  • Developer Integration and Marketing Agreement
  • Privacy policy
  • Partnerships
  • Sign In
  • Sign In

    Loyalty

  • Create loyalty account

  • Search loyalty accounts

  • Retrieve loyalty account

  • Accumulate loyalty points

  • Adjust loyalty points

  • Search loyalty events

  • Retrieve loyalty program

  • Calculate loyalty points

  • List loyalty promotions

  • Create loyalty promotion

  • Retrieve loyalty promotion

  • Cancel loyalty promotion

  • Create loyalty reward

  • Search loyalty rewards

  • Delete loyalty reward

  • Retrieve loyalty reward

  • Redeem loyalty reward

  • Webhooks

  • loyalty.account.created

  • loyalty.account.deleted

  • loyalty.account.updated

  • loyalty.event.created

  • loyalty.program.created

  • loyalty.program.updated

  • loyalty.promotion.created

  • loyalty.promotion.updated

<- Loyalty API

Loyalty API

All versions ->

Search loyalty accounts

POST

 /v2/loyalty/accounts/search

Searches for loyalty accounts in a loyalty program.

You can search for a loyalty account using the phone number or customer ID associated with the account. To return all loyalty accounts, specify an empty query object or omit it entirely.

Search results are sorted by created_at in ascending order.

Permissions:LOYALTY_READ

Guide

Search loyalty accounts

Try in API Explorer
Link to section

Request body

Example code

Link to section

query

The search criteria for the request.

Link to section

limit

integer(32-bit)

The maximum number of results to include in the response. The default value is 30.

Min
1
Max
200
Link to section

cursor

string

A pagination cursor returned by a previous call to this endpoint. Provide this to retrieve the next set of results for the original query.

For more information, see Pagination.

Link to section

Response fields

Link to section

errors

Any errors that occurred during the request.

Link to section

loyalty_accounts

The loyalty accounts that met the search criteria,
in order of creation date.

Link to section

cursor

string

The pagination cursor to use in a subsequent request. If empty, this is the final response. For more information, see Pagination.

Link to section

Examples

All versions ->

POST /v2/loyalty/accounts/search
curl https://connect.squareup.com/v2/loyalty/accounts/search \ -X POST \ -H 'Square-Version: 2026-11-18' \ -H 'Authorization: Bearer ACCESS_TOKEN' \ -H 'Content-Type: application/json' \ -d '{ "query": {}, "limit": 5 }'

Response JSON

{ "loyalty_accounts": [ { "id": "79b807d2-d786-46a9-933b-918028d7a8c5", "mapping": { "id": "66aaab3f-da99-49ed-8b19-b87f851c844f", "phone_number": "+14155551234", "created_at": "2020-05-08T21:44:32Z" }, "program_id": "d619f755-2d17-41f3-990d-c04ecedd64dd", "balance": 20, "lifetime_points": 50, "customer_id": "RPJBC4YA0MTGX8DHTXE9AP2AS4", "created_at": "2020-05-08T21:44:32Z", "updated_at": "2020-05-08T21:44:32Z" }, { "id": "452ea896-f36e-4c5c-95d5-e5aa727b9b2c", "mapping": { "id": "cbde1ec6-96df-40d4-8019-af9a4fa893ed", "phone_number": "+14255554670", "created_at": "2020-05-29T04:04:11Z" }, "program_id": "d619f755-2d17-41f3-990d-c04ecedd64dd", "balance": -10, "lifetime_points": 10, "customer_id": "6E51KR0B3GVAKE0GP0HV69A1V0", "created_at": "2020-05-29T04:04:11Z", "updated_at": "2020-05-29T04:04:11Z" }, { "id": "bd2d7c0d-0183-4c1e-b5d4-d1c88f24c201", "mapping": { "id": "9a85bb43-a6a5-4123-a2e7-324621cf283b", "phone_number": "+12085559707", "created_at": "2020-07-22T10:50:28Z" }, "program_id": "d619f755-2d17-41f3-990d-c04ecedd64dd", "balance": 80, "lifetime_points": 210, "customer_id": "REK96J96AS5AN2Y8Z4H01QWYE8", "created_at": "2020-07-22T10:50:28Z", "updated_at": "2020-07-22T10:50:28Z" }, { "id": "5bb3fc58-266a-4001-bb26-99a178533355", "mapping": { "id": "d0805ad0-7bc7-45e2-ad84-932c226cd096", "phone_number": "+16095552758", "created_at": "2020-09-13T04:27:43Z" }, "program_id": "d619f755-2d17-41f3-990d-c04ecedd64dd", "balance": 40, "lifetime_points": 40, "customer_id": "6WW3N3ZRWMYRSB21ZVW4TT4BYC", "created_at": "2020-09-13T04:27:43Z", "updated_at": "2020-09-13T04:27:43Z" }, { "id": "9f32fe22-777e-4655-8a82-29c1ef51e496", "mapping": { "id": "fccc1899-e8e8-4423-9525-bb5d6453c6ae", "phone_number": "+15055551967", "created_at": "2020-09-18T14:28:57Z" }, "program_id": "d619f755-2d17-41f3-990d-c04ecedd64dd", "balance": 0, "lifetime_points": 0, "customer_id": "3GR8PJ090RYTZ70KPB92YM4YZ0", "created_at": "2020-09-18T14:28:57Z", "updated_at": "2020-09-18T14:28:57Z" } ], "cursor": "LRdH9KdUiYrJqbbouAglvV46UOmVv7VByhTxMK0pprEsQdzlYfwCUiin2Q7FGR9QC" }