---
title: "Transactions"
permalink: "/docs/api-v1/transactions"
description: "RevenueCat API v1 endpoint reference for Transactions."
original_source: "openapi-spec/api-v1.yaml"
---

> **AI agents:** This is the Markdown version of a RevenueCat documentation page. For the complete documentation index, see [llms.txt](https://www.revenuecat.com/docs/llms.txt).


# Transactions | REST API v1 Reference (1.0)

Download OpenAPI specification:[Download](https://www.revenuecat.com/docs/redocusaurus/openapi-v1-transactions.yaml)

RevenueCat API v1 endpoint reference for Transactions.

## <a id="tag/transactions"></a>Transactions

Part of the [REST API v1 Reference](/docs/api-v1).

Operations about transactions.

#### Endpoints

-   [Create a Purchase](#tag/transactions/operation/receipts) — `POST /receipts`
-   [Google Play: Refund and Revoke Subscription](#tag/transactions/operation/revoke-a-google-subscription) — `POST /subscribers/{app_user_id}/subscriptions/{product_identifier}/revoke`
-   [Google Play: Defer a Subscription](#tag/transactions/operation/defer-a-google-subscription) — `POST /subscribers/{app_user_id}/subscriptions/{product_identifier}/defer`
-   [Google Play: Refund and Revoke Purchase](#tag/transactions/operation/refund-a-google-subscription) — `POST /subscribers/{app_user_id}/transactions/{store_transaction_identifier}/refund`
-   [Google Play: Cancel a Subscription](#tag/transactions/operation/cancel-a-google-subscription) — `POST /subscribers/{app_user_id}/subscriptions/{store_transaction_identifier}/cancel`
-   [App Store: Extend a Subscription](#tag/transactions/operation/extend-an-apple-subscription) — `POST /subscribers/{app_user_id}/subscriptions/{store_transaction_identifier}/extend`

## <a id="tag/transactions/operation/receipts"></a>Create a Purchase

post/receipts

https://api.revenuecat.com/v1/receipts

Records a purchase for a Customer from iOS, Android, Stripe, Roku and Paddle will create a Customer if they don't already exist.

##### Authorizations:

_BearerAuth_

##### header Parameters

- `X-Platform` (required): string Example: ios — The platform this purchase is for. Either `ios`, `android`, `amazon`, `macos`, `uikitformac`, `stripe`, `roku`, or `paddle`

##### Request Body schema: application/json

- `app_user_id` (required): string — App User ID of the Customer the receipt is associated with.
- `fetch_token` (required): string — For iOS, the base64 encoded receipt file (or JWSTransaction for StoreKit2), for Android the receipt token, for Amazon the receipt, for Stripe the subscription ID or the Stripe Checkout Session ID, for Roku the transaction ID, and for Paddle the subscription ID or transaction ID.
- `product_id`: string — The Apple, Google, Amazon, Roku, or Paddle product identifier or SKU. Required for Google.
- `price`: number `float` — The price of the product. **Required if you provide a currency.**
- `currency`: string Default: "USD" — The currency of the product. The currency must be in [ISO 4217 format](https://en.wikipedia.org/wiki/ISO_4217). **Required if you provide a price.**
- `payment_mode`: string — Optionally used by the iOS SDK to communicate intro pricing periods. Either `pay_as_you_go = 0`, `pay_up_front = 1`, or `free_trial = 2`. Defaults to `2` (free trial) if an introductory period is detected in the receipt but this value is not provided.
- `introductory_price`: number `float` — Introductory price paid
- `is_restore`: boolean Deprecated Default: false — If true, the fetch token will trigger your configured [restore behavior](https://www.revenuecat.com/docs/restoring-purchases#restore-behavior) for any other users sharing the same fetch token.
- `presented_offering_identifier`: string — Optional. The offering that was presented to the Customer at the time of purchase. This will be attached to any new transactions in this fetch token and will be available in ETL exports and webhooks. This is mostly useful if you're sending fetch tokens from your backend.
- `attributes`: object — Any [Attributes](/docs/customers/customer-attributes) to set on the Customer as a dictionary keyed by the Attribute name.
    - `value` (required): string — The value of the attribute. If the value is `null` or an empty string, the attribute will be deleted.
    - `updated_at_ms`: integer `int64` — UNIX epoch in milliseconds of when the attribute was updated. This value is used to resolve conflicts, an attribute will only be updated if the new `updated_at_ms` value is newer than the value for the stored attribute.

### Responses

**200**

Purchase was successfully posted.

Returns the updated [Customer Info](/docs/api-v1/customer-info-model#tag/customer_info_model) for the Customer for which the purchase was posted.

### Request samples

Content type

application/json

 

```json
{
  "app_user_id": "string",
  "fetch_token": "string",
  "product_id": "com.my.product.iap",
  "price": 1.99,
  "currency": "USD",
  "payment_mode": "string",
  "introductory_price": 0.1,
  "is_restore": false,
  "presented_offering_identifier": "string",
  "attributes": {
    "property1": {
      "value": "string",
      "updated_at_ms": 1709195668093
    },
    "property2": {
      "value": "string",
      "updated_at_ms": 1709195668093
    }
  }
}
```

### Response samples

Content type

application/json

 

```json
{
  "value": {
    "request_date": "2019-07-26T17:40:10Z",
    "request_date_ms": 1564162810884,
    "subscriber": {
      "entitlements": {
        "pro_cat": {
          "expires_date": null,
          "grace_period_expires_date": null,
          "product_identifier": "onetime",
          "purchase_date": "2019-04-05T21:52:45Z"
        }
      },
      "first_seen": "2019-02-21T00:08:41Z",
      "management_url": "https://apps.apple.com/account/subscriptions",
      "non_subscriptions": {
        "onetime": [
          {
            "id": "cadba0c81b",
            "is_sandbox": true,
            "purchase_date": "2019-04-05T21:52:45Z",
            "store": "app_store"
          }
        ]
      },
      "original_app_user_id": "XXX-XXXXX-XXXXX-XX",
      "original_application_version": "1.0",
      "original_purchase_date": "2019-01-30T23:54:10Z",
      "other_purchases": { },
      "subscriptions": {
        "annual": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-14T21:07:40Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-07-14T20:07:40Z",
          "refunded_at": null,
          "store": "play_store",
          "store_transaction_id": "GPA.6801-7988-0152-76034..5",
          "unsubscribe_detected_at": "2019-07-17T22:48:38Z"
        },
        "onemonth": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-06-17T22:47:55Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-06-17T22:42:55Z",
          "refunded_at": null,
          "store": "app_store",
          "store_transaction_id": 1000000652379790,
          "unsubscribe_detected_at": "2019-06-17T22:48:38Z"
        },
        "rc_promo_pro_cat_monthly": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-26T01:02:16Z",
          "grace_period_expires_date": null,
          "is_sandbox": false,
          "original_purchase_date": "2019-07-26T01:02:16Z",
          "ownership_type": "FAMILY_SHARED",
          "period_type": "normal",
          "purchase_date": "2019-07-26T01:02:16Z",
          "refunded_at": null,
          "store": "promotional",
          "store_transaction_id": "a42db3af39530cb82b17eaf9c6576393",
          "unsubscribe_detected_at": null
        }
      }
    }
  }
}
```

## <a id="tag/transactions/operation/revoke-a-google-subscription"></a>Google Play: Refund and Revoke Subscription

post/subscribers/{app_user_id}/subscriptions/{product_identifier}/revoke

https://api.revenuecat.com/v1/subscribers/{app_user_id}/subscriptions/{product_identifier}/revoke

Immediately revokes access to a Google Subscription and issues a refund for the last purchase. If you want to refund a one-time Google purchase, see [refund a Google purchase](#tag/transactions/operation/revoke-a-google-subscription).

##### Authorizations:

_BearerAuth_

##### path Parameters

- `app_user_id` (required): string — The App User ID of the Customer.
- `product_identifier` (required): string — The identifier of the product belonging to the subscription that is being revoked.

### Responses

**200**

Subscription was successfully refunded and revoked.

Returns the updated [Customer Info](/docs/api-v1/customer-info-model#tag/customer_info_model) for the Customer.

### Response samples

Content type

application/json

 

```json
{
  "value": {
    "request_date": "2019-07-26T17:40:10Z",
    "request_date_ms": 1564162810884,
    "subscriber": {
      "entitlements": {
        "pro_cat": {
          "expires_date": null,
          "grace_period_expires_date": null,
          "product_identifier": "onetime",
          "purchase_date": "2019-04-05T21:52:45Z"
        }
      },
      "first_seen": "2019-02-21T00:08:41Z",
      "management_url": "https://apps.apple.com/account/subscriptions",
      "non_subscriptions": {
        "onetime": [
          {
            "id": "cadba0c81b",
            "is_sandbox": true,
            "purchase_date": "2019-04-05T21:52:45Z",
            "store": "app_store"
          }
        ]
      },
      "original_app_user_id": "XXX-XXXXX-XXXXX-XX",
      "original_application_version": "1.0",
      "original_purchase_date": "2019-01-30T23:54:10Z",
      "other_purchases": { },
      "subscriptions": {
        "annual": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-14T21:07:40Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-07-14T20:07:40Z",
          "refunded_at": null,
          "store": "play_store",
          "store_transaction_id": "GPA.6801-7988-0152-76034..5",
          "unsubscribe_detected_at": "2019-07-17T22:48:38Z"
        },
        "onemonth": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-06-17T22:47:55Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-06-17T22:42:55Z",
          "refunded_at": null,
          "store": "app_store",
          "store_transaction_id": 1000000652379790,
          "unsubscribe_detected_at": "2019-06-17T22:48:38Z"
        },
        "rc_promo_pro_cat_monthly": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-26T01:02:16Z",
          "grace_period_expires_date": null,
          "is_sandbox": false,
          "original_purchase_date": "2019-07-26T01:02:16Z",
          "ownership_type": "FAMILY_SHARED",
          "period_type": "normal",
          "purchase_date": "2019-07-26T01:02:16Z",
          "refunded_at": null,
          "store": "promotional",
          "store_transaction_id": "a42db3af39530cb82b17eaf9c6576393",
          "unsubscribe_detected_at": null
        }
      }
    }
  }
}
```

## <a id="tag/transactions/operation/defer-a-google-subscription"></a>Google Play: Defer a Subscription

post/subscribers/{app_user_id}/subscriptions/{product_identifier}/defer

https://api.revenuecat.com/v1/subscribers/{app_user_id}/subscriptions/{product_identifier}/defer

Defers the purchase of a Google Subscription to a later date.

##### Authorizations:

_BearerAuth_

##### path Parameters

- `app_user_id` (required): string — The App User ID of the Customer.
- `product_identifier` (required): string — The identifier of the product belonging to the subscription that is being deferred. This can be found in RevenueCat's Product catalog -> {Product} -> Subscription Id.

##### Request Body schema: application/json

- `expiry_time_ms`: integer `int64` — The desired next expiry time to assign to the subscription, in milliseconds since the Epoch. The given time must be later/greater than the current expiry time for the subscription. Either `expiry_time_ms` or `extend_by_days` must be provided.
- `extend_by_days`: integer [ 1 .. 365 ] — The number of days to extend the subscription renewal date. Must be between 1 and 365. Either `expiry_time_ms` or `extend_by_days` must be provided.

### Responses

**200**

Subscription was successfully deferred.

Returns the updated [Customer Info](/docs/api-v1/customer-info-model#tag/customer_info_model) for the Customer.

### Request samples

Content type

application/json

```json
{
  "expiry_time_ms": 1708417962662,
  "extend_by_days": 30
}
```

### Response samples

Content type

application/json

 

```json
{
  "value": {
    "request_date": "2019-07-26T17:40:10Z",
    "request_date_ms": 1564162810884,
    "subscriber": {
      "entitlements": {
        "pro_cat": {
          "expires_date": null,
          "grace_period_expires_date": null,
          "product_identifier": "onetime",
          "purchase_date": "2019-04-05T21:52:45Z"
        }
      },
      "first_seen": "2019-02-21T00:08:41Z",
      "management_url": "https://apps.apple.com/account/subscriptions",
      "non_subscriptions": {
        "onetime": [
          {
            "id": "cadba0c81b",
            "is_sandbox": true,
            "purchase_date": "2019-04-05T21:52:45Z",
            "store": "app_store"
          }
        ]
      },
      "original_app_user_id": "XXX-XXXXX-XXXXX-XX",
      "original_application_version": "1.0",
      "original_purchase_date": "2019-01-30T23:54:10Z",
      "other_purchases": { },
      "subscriptions": {
        "annual": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-14T21:07:40Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-07-14T20:07:40Z",
          "refunded_at": null,
          "store": "play_store",
          "store_transaction_id": "GPA.6801-7988-0152-76034..5",
          "unsubscribe_detected_at": "2019-07-17T22:48:38Z"
        },
        "onemonth": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-06-17T22:47:55Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-06-17T22:42:55Z",
          "refunded_at": null,
          "store": "app_store",
          "store_transaction_id": 1000000652379790,
          "unsubscribe_detected_at": "2019-06-17T22:48:38Z"
        },
        "rc_promo_pro_cat_monthly": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-26T01:02:16Z",
          "grace_period_expires_date": null,
          "is_sandbox": false,
          "original_purchase_date": "2019-07-26T01:02:16Z",
          "ownership_type": "FAMILY_SHARED",
          "period_type": "normal",
          "purchase_date": "2019-07-26T01:02:16Z",
          "refunded_at": null,
          "store": "promotional",
          "store_transaction_id": "a42db3af39530cb82b17eaf9c6576393",
          "unsubscribe_detected_at": null
        }
      }
    }
  }
}
```

## <a id="tag/transactions/operation/refund-a-google-subscription"></a>Google Play: Refund and Revoke Purchase

post/subscribers/{app_user_id}/transactions/{store_transaction_identifier}/refund

https://api.revenuecat.com/v1/subscribers/{app_user_id}/transactions/{store_transaction_identifier}/refund

Issues a refund for the specified transaction and revokes access. Works for subscription and non-subscription purchases that occurred in the last 365 days.

##### Authorizations:

_BearerAuth_

##### path Parameters

- `app_user_id` (required): string — The App User ID of the Customer.
- `store_transaction_identifier` (required): string — The identifier of the transaction to refund. Example: GPA.3309-9122-6177-45730

### Responses

**200**

Purchase was successfully refunded and revoked.

Returns the updated [Customer Info](/docs/api-v1/customer-info-model#tag/customer_info_model) for the Customer.

### Response samples

Content type

application/json

 

```json
{
  "value": {
    "request_date": "2019-07-26T17:40:10Z",
    "request_date_ms": 1564162810884,
    "subscriber": {
      "entitlements": {
        "pro_cat": {
          "expires_date": null,
          "grace_period_expires_date": null,
          "product_identifier": "onetime",
          "purchase_date": "2019-04-05T21:52:45Z"
        }
      },
      "first_seen": "2019-02-21T00:08:41Z",
      "management_url": "https://apps.apple.com/account/subscriptions",
      "non_subscriptions": {
        "onetime": [
          {
            "id": "cadba0c81b",
            "is_sandbox": true,
            "purchase_date": "2019-04-05T21:52:45Z",
            "store": "app_store"
          }
        ]
      },
      "original_app_user_id": "XXX-XXXXX-XXXXX-XX",
      "original_application_version": "1.0",
      "original_purchase_date": "2019-01-30T23:54:10Z",
      "other_purchases": { },
      "subscriptions": {
        "annual": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-14T21:07:40Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-07-14T20:07:40Z",
          "refunded_at": null,
          "store": "play_store",
          "store_transaction_id": "GPA.6801-7988-0152-76034..5",
          "unsubscribe_detected_at": "2019-07-17T22:48:38Z"
        },
        "onemonth": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-06-17T22:47:55Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-06-17T22:42:55Z",
          "refunded_at": null,
          "store": "app_store",
          "store_transaction_id": 1000000652379790,
          "unsubscribe_detected_at": "2019-06-17T22:48:38Z"
        },
        "rc_promo_pro_cat_monthly": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-26T01:02:16Z",
          "grace_period_expires_date": null,
          "is_sandbox": false,
          "original_purchase_date": "2019-07-26T01:02:16Z",
          "ownership_type": "FAMILY_SHARED",
          "period_type": "normal",
          "purchase_date": "2019-07-26T01:02:16Z",
          "refunded_at": null,
          "store": "promotional",
          "store_transaction_id": "a42db3af39530cb82b17eaf9c6576393",
          "unsubscribe_detected_at": null
        }
      }
    }
  }
}
```

## <a id="tag/transactions/operation/cancel-a-google-subscription"></a>Google Play: Cancel a Subscription

post/subscribers/{app_user_id}/subscriptions/{store_transaction_identifier}/cancel

https://api.revenuecat.com/v1/subscribers/{app_user_id}/subscriptions/{store_transaction_identifier}/cancel

Cancels a Google subscription. The subscription remains valid until its expiration time, but it will not renew.

##### Authorizations:

_BearerAuth_

##### path Parameters

- `app_user_id` (required): string — The App User ID of the Customer.
- `store_transaction_identifier` (required): string — The identifier of the transaction to cancel. Example: GPA.3309-9122-6177-45730

### Responses

**200**

Subscription was successfully canceled.

Returns the updated [Customer Info](/docs/api-v1/customer-info-model#tag/customer_info_model) for the Customer.

### Response samples

Content type

application/json

 

```json
{
  "value": {
    "request_date": "2019-07-26T17:40:10Z",
    "request_date_ms": 1564162810884,
    "subscriber": {
      "entitlements": {
        "pro_cat": {
          "expires_date": null,
          "grace_period_expires_date": null,
          "product_identifier": "onetime",
          "purchase_date": "2019-04-05T21:52:45Z"
        }
      },
      "first_seen": "2019-02-21T00:08:41Z",
      "management_url": "https://apps.apple.com/account/subscriptions",
      "non_subscriptions": {
        "onetime": [
          {
            "id": "cadba0c81b",
            "is_sandbox": true,
            "purchase_date": "2019-04-05T21:52:45Z",
            "store": "app_store"
          }
        ]
      },
      "original_app_user_id": "XXX-XXXXX-XXXXX-XX",
      "original_application_version": "1.0",
      "original_purchase_date": "2019-01-30T23:54:10Z",
      "other_purchases": { },
      "subscriptions": {
        "annual": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-14T21:07:40Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-07-14T20:07:40Z",
          "refunded_at": null,
          "store": "play_store",
          "store_transaction_id": "GPA.6801-7988-0152-76034..5",
          "unsubscribe_detected_at": "2019-07-17T22:48:38Z"
        },
        "onemonth": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-06-17T22:47:55Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-06-17T22:42:55Z",
          "refunded_at": null,
          "store": "app_store",
          "store_transaction_id": 1000000652379790,
          "unsubscribe_detected_at": "2019-06-17T22:48:38Z"
        },
        "rc_promo_pro_cat_monthly": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-26T01:02:16Z",
          "grace_period_expires_date": null,
          "is_sandbox": false,
          "original_purchase_date": "2019-07-26T01:02:16Z",
          "ownership_type": "FAMILY_SHARED",
          "period_type": "normal",
          "purchase_date": "2019-07-26T01:02:16Z",
          "refunded_at": null,
          "store": "promotional",
          "store_transaction_id": "a42db3af39530cb82b17eaf9c6576393",
          "unsubscribe_detected_at": null
        }
      }
    }
  }
}
```

## <a id="tag/transactions/operation/extend-an-apple-subscription"></a>App Store: Extend a Subscription

post/subscribers/{app_user_id}/subscriptions/{store_transaction_identifier}/extend

https://api.revenuecat.com/v1/subscribers/{app_user_id}/subscriptions/{store_transaction_identifier}/extend

Extends the renewal date of an auto-renewable subscription for up to 90 days for a specific customer.

This uses Apple's [Extend a Subscription Renewal Date](https://developer.apple.com/documentation/appstoreserverapi/extend_a_subscription_renewal_date) API.

**Requires a v1 Secret API key.**

Note: Apple limits subscription extensions to two per year per customer. Apple immediately sends the customer an email notification of the extension.

##### Authorizations:

_BearerAuth_

##### path Parameters

- `app_user_id` (required): string — The App User ID of the Customer.
- `store_transaction_identifier` (required): string — The store transaction identifier of the subscription to extend. Can be original transaction identifier or renewal transaction identifier. Example: 1000000819074923

##### Request Body schema: application/json

- `extend_by_days` (required): integer [ 1 .. 90 ] — The number of days to extend the subscription renewal date. Must be between 1 and 90.
- `extend_reason_code` (required): integer [ 0 .. 3 ] — The reason code for the subscription extension. See Apple's [extendReasonCode](https://developer.apple.com/documentation/appstoreserverapi/extendreasoncode) documentation. * `0`: Undeclared - The renewal-date extension reason is undeclared. * `1`: Customer Satisfaction - The renewal-date extension is for customer satisfaction. * `2`: Other - The renewal-date extension is for a reason other than the ones listed. * `3`: Service Issue or Outage - The renewal-date extension is due to a service issue or outage.

### Responses

**200**

Subscription was successfully extended.

Returns the updated [Customer Info](/docs/api-v1/customer-info-model#tag/customer_info_model) for the Customer.

### Request samples

Content type

application/json

```json
{
  "extend_by_days": 30,
  "extend_reason_code": 1
}
```

### Response samples

Content type

application/json

 

```json
{
  "value": {
    "request_date": "2019-07-26T17:40:10Z",
    "request_date_ms": 1564162810884,
    "subscriber": {
      "entitlements": {
        "pro_cat": {
          "expires_date": null,
          "grace_period_expires_date": null,
          "product_identifier": "onetime",
          "purchase_date": "2019-04-05T21:52:45Z"
        }
      },
      "first_seen": "2019-02-21T00:08:41Z",
      "management_url": "https://apps.apple.com/account/subscriptions",
      "non_subscriptions": {
        "onetime": [
          {
            "id": "cadba0c81b",
            "is_sandbox": true,
            "purchase_date": "2019-04-05T21:52:45Z",
            "store": "app_store"
          }
        ]
      },
      "original_app_user_id": "XXX-XXXXX-XXXXX-XX",
      "original_application_version": "1.0",
      "original_purchase_date": "2019-01-30T23:54:10Z",
      "other_purchases": { },
      "subscriptions": {
        "annual": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-14T21:07:40Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-07-14T20:07:40Z",
          "refunded_at": null,
          "store": "play_store",
          "store_transaction_id": "GPA.6801-7988-0152-76034..5",
          "unsubscribe_detected_at": "2019-07-17T22:48:38Z"
        },
        "onemonth": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-06-17T22:47:55Z",
          "grace_period_expires_date": null,
          "is_sandbox": true,
          "original_purchase_date": "2019-02-21T00:42:05Z",
          "ownership_type": "PURCHASED",
          "period_type": "normal",
          "purchase_date": "2019-06-17T22:42:55Z",
          "refunded_at": null,
          "store": "app_store",
          "store_transaction_id": 1000000652379790,
          "unsubscribe_detected_at": "2019-06-17T22:48:38Z"
        },
        "rc_promo_pro_cat_monthly": {
          "auto_resume_date": null,
          "billing_issues_detected_at": null,
          "expires_date": "2019-08-26T01:02:16Z",
          "grace_period_expires_date": null,
          "is_sandbox": false,
          "original_purchase_date": "2019-07-26T01:02:16Z",
          "ownership_type": "FAMILY_SHARED",
          "period_type": "normal",
          "purchase_date": "2019-07-26T01:02:16Z",
          "refunded_at": null,
          "store": "promotional",
          "store_transaction_id": "a42db3af39530cb82b17eaf9c6576393",
          "unsubscribe_detected_at": null
        }
      }
    }
  }
}
```

## <a id="tag/Endpoint-Reference"></a>Endpoint Reference

All API v1 resources, one page each. General concepts (authentication, request format, URL parameters) live on the [API v1 overview](/docs/api-v1).

-   [Customer Info Model](/docs/api-v1/customer-info-model) — full schema reference
-   [Customers](/docs/api-v1/customers) — 4 endpoints
-   [Entitlements](/docs/api-v1/entitlements) — 2 endpoints
-   [Offerings](/docs/api-v1/offerings) — 3 endpoints
-   [Offerings Model](/docs/api-v1/offerings-model) — full schema reference
-   [Transactions](/docs/api-v1/transactions) — 6 endpoints

## Response schema reference

Response examples above mirror the rendered API reference. These field definitions come from the same OpenAPI specification.

### Subscriber

- Used by `POST /receipts (200) — Create a Purchase`
- Used by `POST /subscribers/{app_user_id}/subscriptions/{product_identifier}/revoke (200) — Google Play: Refund and Revoke Subscription`
- Used by `POST /subscribers/{app_user_id}/subscriptions/{product_identifier}/defer (200) — Google Play: Defer a Subscription`
- Used by `POST /subscribers/{app_user_id}/transactions/{store_transaction_identifier}/refund (200) — Google Play: Refund and Revoke Purchase`
- Used by `POST /subscribers/{app_user_id}/subscriptions/{store_transaction_identifier}/cancel (200) — Google Play: Cancel a Subscription`
- Used by `POST /subscribers/{app_user_id}/subscriptions/{store_transaction_identifier}/extend (200) — App Store: Extend a Subscription`

- `request_date`: string — Date of the request in ISO 8601 format.
- `request_date_ms`: integer (format: `int64`) — Date of the request in milliseconds since Epoch.
- `subscriber`: object — Information about the Customer.
  - `entitlements`: object — Dictionary of the entitlements of this Customer (including any expired entitlements).
  - `first_seen`: string — The ISO 8601 datetime string corresponding to when the Customer was first seen by RevenueCat.
  - `last_seen`: string — The ISO 8601 datetime string corresponding to when the Customer was last seen by RevenueCat.
  - `management_url`: string — URL to manage the active subscription of the Customer. If the Customer has an active App Store subscription, this will point to the App Store. If the Customer has an active Play Store subscription, it will point there. Amazon subscriptions point to the Amazon subscription management page, Paddle subscriptions point to the Paddle Customer Portal, and RevenueCat Web Billing subscriptions point to the RevenueCat Web Billing Customer Portal. For Stripe Billing subscriptions, this returns the configured Stripe Customer Portal URL or a custom URL. If no Stripe Customer Portal URL is configured, this will be null. If there are no active subscriptions it will be null. If the Customer has multiple active subscriptions for different platforms, this will take the value of the OS in the `X-Platform` header into consideration: - If the request was made on an OS for which there are active subscriptions, this will return the URL for the store that matches the header. - If the request was made on a different OS or the OS was not included in the X-Platform header, this will return the URL for the store of the subscription with the farthest future expiration date.
  - `non_subscriptions`: object — Non-subscription purchases of the Customer, keyed by the product identifier.
  - `original_app_user_id`: string — The App User ID under which this Customer was first known to RevenueCat.
  - `original_application_version`: string — *Only available on iOS*. This will be `null` until an iOS receipt is sent for the Customer. After a receipt has been sent, it will indicate the first App Store version of your app that the Customer installed.
  - `original_purchase_date`: string — **Only available on iOS**. The date that the app was first purchased/downloaded by the Customer. Will be `null` if no receipt is recorded for the Customer. Useful for [Migrating Subscriptions](/docs/migrating-to-revenuecat/migrating-existing-subscriptions).
  - `other_purchases`: object
  - `subscriber_attributes`: object — A dictionary of any Attributes set on this Customer. **Only included in responses to requests made with a secret API key**.
  - `subscriptions`: object — Subscription purchases of the Customer, keyed by the product identifier.
