Link Search Menu Expand Document

Subscription Customers


Customers list

Get

GET “https://app.ongoingsubscriptions.com/api/v1/customers”

Description

Get a paginated list of all Subscriptions

Example Response

{
  "customers": [
    {
      "uuid": "7ed9b41c-b3cb-11ec-8006-0242ac130003",
      "displayName": "Michael Angelo",
      "shopifyId": "gid://shopify/Customer/6077936828652",
      "shopUuid": "a132042c-b111-11ec-a8c1-0242ac130003",
      "createdAt": "2022-02-01T15:55:43.000000Z",
      "updatedAt": "2022-03-15T12:06:35.000000Z"
    },
    {
      "uuid": "7ed9b41c-b3cb-11ec-8006-0242ac130003",
      "displayName": "Michael Angelo",
      "shopifyId": "gid://shopify/Customer/6077936828652",
      "shopUuid": "a132042c-b111-11ec-a8c1-0242ac130003",
      "createdAt": "2022-02-01T15:55:43.000000Z",
      "updatedAt": "2022-03-15T12:06:35.000000Z"
    }
  ],
  "pagination": {
    "hasNextPage": true,
    "lastPage": 15,
    "page": 2,
    "totalResults": 2516
  },
  "message": "Customers fetched successfully.",
  "errors": false
}

Single customer

GET “https://app.ongoingsubscriptions.com/api/v1/customers/{uuid}”

Description

Get a single customer and a list of all of their subscriptions.

Url Params

  • uuid: REQUIRED uuid

Example Response

{
  "customer": {
    "uuid": "7ed9b41c-b3cb-11ec-8006-0242ac130003",
    "displayName": "Michael Angelo",
    "shopifyId": "gid://shopify/Customer/6077936828652",
    "shopUuid": "a132042c-b111-11ec-a8c1-0242ac130003",
    "createdAt": "2022-02-01T23:15:37.000000Z",
    "updatedAt": "2022-03-01T01:28:23.000000Z"
  },
  "subscriptions": [
    {
      "uuid": "7cf1a0a6-b3cb-11ec-9a1b-0242ac130003",
      "status": "ACTIVE",
      "createdAt": "2022-02-01T23:15:37.000000Z",
      "updatedAt": "2022-03-01T01:28:23.000000Z"
    }
  ],
  "message": "Customer fetched successfully.",
  "errors": false
}

POST “https://app.ongoingsubscriptions.com/api/v1/portal-link”

Description

Send the portal login link to the saved email address for a customer

Request Params

  • subscriptionUuid: REQUIRED uuid

    Example: 7cf1a0a6-b3cb-11ec-9a1b-0242ac130003

Example Response

{
  "message": "Portal login link sent successfully.",
  "errors": false
}

Send customer payment update instructions

POST “https://app.ongoingsubscriptions.com/api/v1/payment-method”

Description

Send an email from Shopify to the subscription customer with information about updating their payment details.

Request Params

  • customerUuid: REQUIRED uuid

    Example: 7cf1a0a6-b3cb-11ec-9a1b-0242ac130003

  • customerPaymentMethodId: REQUIRED shopifyId

    Example: gid://shopify/CustomerPaymentMethod/67342c35daf453460251a

Example Response

{
  "customer": [
    "email": "example@gmail.com"
  ],
  "message": "Email sent successfully.",
  "errors": false
}