---
title: "Renew subscription"
method: POST
path: "/subscriptions/{subscriptionId}/renew"
---

# Renew subscription

`POST /subscriptions/{subscriptionId}/renew`

Use this endpoint to renew [externally-managed subscriptions](https://developers.cleeng.com/docs/externally-managed-subscriptions) (EMS) - subscriptions whose life cycle is managed outside of Cleeng.

## Path parameters

- `subscriptionId` integer, required

## Headers

- `Content-Type` string

## Request body

- object
  - `expiresAt` integer — Expiration time in UNIX timestamp format.
  - `paymentId` integer — The identifier of Cleeng payment.
  - `convertTrial` boolean — Indicates whether a subscription should be converted to a paid subscription during the renewal process. If not provided, defaults to `false`. If set to `true`, it will convert the trial on subscription to `0`. <br /> Example: `convertTrial`: `true`

## Response `200`

200

- object
  - `subscriptionId` integer
  - `paymentDetailsId` unknown
  - `publisherId` integer
  - `customerId` integer
  - `status` string
  - `dateFrom` integer
  - `dateTo` integer
  - `nextPaymentAction` string
  - `nextPaymentActionDate` integer
  - `subscriptionExternalId` string
  - `offerId` string
  - `paymentCountry` string
  - `ipAddress` unknown
  - `inTrial` boolean
  - `couponCode` unknown
  - `coupon` object
    - `discountRate` integer
    - `usageLeft` integer
  - `pendingSwitchId` unknown
  - `externalProperties` object
  - `paymentMethodId` integer
  - `isExternallyManaged` boolean
  - `replacedBy` object
    - `subscriptionId` integer
    - `reason` string
    - `date` integer
  - `originatedFrom` object
    - `subscriptionId` integer
    - `reason` string
    - `date` integer
  - `source` string
  - `renewalCycle` object
    - `completed` integer
    - `unit` string
    - `amount` integer
  - `terminationType` unknown

## Other responses

- `400` — 400
- `404` — 404
- `422` — 422

---

[API](https://skmtc.net/cleeng/apis/mediastore-api.md) · [All operations](https://skmtc.net/cleeng/apis/mediastore-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cleeng/mediastore-api/versions/00cbfe7998a4/schema)
