# Product

## Create Product

> Creates a new subscription product. The Subscription API charges on a recurring basis according to pricing plans, and each plan is linked to at least one product. There is no limit on the number of products; a product can be created by providing only a name.

```json
{"openapi":"3.0.3","info":{"title":"Subscription Product","version":"1.0.0"},"tags":[{"name":"Subscription Product","description":"Subscription product management services."}],"servers":[{"url":"https://api.iyzipay.com","description":"iyzico API"}],"paths":{"/v2/subscription/products":{"post":{"summary":"Create Product","operationId":"createSubscriptionProduct","description":"Creates a new subscription product. The Subscription API charges on a recurring basis according to pricing plans, and each plan is linked to at least one product. There is no limit on the number of products; a product can be created by providing only a name.","tags":["Subscription Product"],"parameters":[{"$ref":"#/components/parameters/AuthHeader"},{"$ref":"#/components/parameters/ContentTypeHeader"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionProductCreateRequest"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionProductCreateSuccess"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}},"components":{"parameters":{"AuthHeader":{"name":"Authorization","in":"header","required":true,"description":"Authorization header; a signed hash value that starts with **IYZWSv2** and is generated in Base64 format.","schema":{"type":"string"}},"ContentTypeHeader":{"name":"Content-Type","in":"header","required":true,"description":"Content type of the request body.","schema":{"type":"string"}}},"schemas":{"SubscriptionProductCreateRequest":{"type":"object","properties":{"locale":{"type":"string","description":"Language of iyzico response messages. Default **en**; **tr** is supported."},"conversationId":{"type":"string","description":"A reference value that can be used to match request and response."},"name":{"type":"string","description":"Product name."},"description":{"type":"string","description":"Product description."}},"required":["name"]},"SubscriptionProductCreateSuccess":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."},"data":{"$ref":"#/components/schemas/ProductResource"}}},"ProductResource":{"type":"object","description":"Product details.","properties":{"referenceCode":{"type":"string","description":"Unique reference code of the product."},"createdDate":{"type":"string","description":"Product creation date (`YYYY-MM-DD hh:mm:ss`)."},"name":{"type":"string","description":"Product name."},"description":{"type":"string","description":"Product description."},"status":{"type":"string","description":"Product status (default ACTIVE)."},"pricingPlans":{"type":"array","description":"List of plans linked to the product.","items":{"$ref":"#/components/schemas/PricingPlanBrief"}}}},"PricingPlanBrief":{"type":"object","description":"Summary view of the plan linked to the product.","properties":{"referenceCode":{"type":"string","description":"Unique reference code of the plan."},"createdDate":{"type":"string","description":"Plan creation date (`YYYY-MM-DD hh:mm:ss`)."},"name":{"type":"string","description":"Plan name."},"price":{"type":"decimal","description":"Plan price (Decimal)."},"paymentInterval":{"type":"string","enum":["WEEKLY","MONTHLY","DAILY","YEARLY"],"description":"Payment frequency."},"paymentIntervalCount":{"type":"integer","description":"Number of repeats for the payment interval."},"trialPeriodDays":{"type":"integer","description":"Trial period (days)."},"currencyCode":{"type":"string","description":"Currency (e.g., TRY)."},"productReferenceCode":{"type":"string","description":"Reference code of the product the plan belongs to."},"planPaymentType":{"type":"string","description":"Plan payment type (RECURRING)."},"status":{"type":"string","description":"Plan status (e.g., ACTIVE)."},"recurrenceCount":{"type":"integer","description":"Total number of recurrences (if any)."}}},"ErrorResponse":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"errorCode":{"type":"string","description":"Error code."},"errorMessage":{"type":"string","description":"Error message."},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."}}}}}}
```

## Update Product

> Updates a subscription product. Product name and description can be edited via API or the iyzico merchant panel. Use the product’s unique reference code for API updates.

```json
{"openapi":"3.0.3","info":{"title":"Subscription Product","version":"1.0.0"},"tags":[{"name":"Subscription Product","description":"Subscription product management services."}],"servers":[{"url":"https://api.iyzipay.com","description":"iyzico API"}],"paths":{"/v2/subscription/products/{productReferenceCode}":{"post":{"summary":"Update Product","operationId":"updateSubscriptionProduct","description":"Updates a subscription product. Product name and description can be edited via API or the iyzico merchant panel. Use the product’s unique reference code for API updates.","tags":["Subscription Product"],"parameters":[{"$ref":"#/components/parameters/AuthHeader"},{"$ref":"#/components/parameters/ContentTypeHeader"},{"name":"productReferenceCode","in":"path","required":true,"schema":{"type":"string"},"description":"Unique reference code of the product."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionProductUpdateRequest"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionProductGetSuccess"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}},"components":{"parameters":{"AuthHeader":{"name":"Authorization","in":"header","required":true,"description":"Authorization header; a signed hash value that starts with **IYZWSv2** and is generated in Base64 format.","schema":{"type":"string"}},"ContentTypeHeader":{"name":"Content-Type","in":"header","required":true,"description":"Content type of the request body.","schema":{"type":"string"}}},"schemas":{"SubscriptionProductUpdateRequest":{"type":"object","properties":{"locale":{"type":"string","description":"Response language (**en**/**tr**)."},"conversationId":{"type":"string","description":"Value used for request/response matching."},"name":{"type":"string","description":"New product name."},"description":{"type":"string","description":"New product description."}},"required":["name"]},"SubscriptionProductGetSuccess":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."},"data":{"$ref":"#/components/schemas/ProductResource"}}},"ProductResource":{"type":"object","description":"Product details.","properties":{"referenceCode":{"type":"string","description":"Unique reference code of the product."},"createdDate":{"type":"string","description":"Product creation date (`YYYY-MM-DD hh:mm:ss`)."},"name":{"type":"string","description":"Product name."},"description":{"type":"string","description":"Product description."},"status":{"type":"string","description":"Product status (default ACTIVE)."},"pricingPlans":{"type":"array","description":"List of plans linked to the product.","items":{"$ref":"#/components/schemas/PricingPlanBrief"}}}},"PricingPlanBrief":{"type":"object","description":"Summary view of the plan linked to the product.","properties":{"referenceCode":{"type":"string","description":"Unique reference code of the plan."},"createdDate":{"type":"string","description":"Plan creation date (`YYYY-MM-DD hh:mm:ss`)."},"name":{"type":"string","description":"Plan name."},"price":{"type":"decimal","description":"Plan price (Decimal)."},"paymentInterval":{"type":"string","enum":["WEEKLY","MONTHLY","DAILY","YEARLY"],"description":"Payment frequency."},"paymentIntervalCount":{"type":"integer","description":"Number of repeats for the payment interval."},"trialPeriodDays":{"type":"integer","description":"Trial period (days)."},"currencyCode":{"type":"string","description":"Currency (e.g., TRY)."},"productReferenceCode":{"type":"string","description":"Reference code of the product the plan belongs to."},"planPaymentType":{"type":"string","description":"Plan payment type (RECURRING)."},"status":{"type":"string","description":"Plan status (e.g., ACTIVE)."},"recurrenceCount":{"type":"integer","description":"Total number of recurrences (if any)."}}},"ErrorResponse":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"errorCode":{"type":"string","description":"Error code."},"errorMessage":{"type":"string","description":"Error message."},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."}}}}}}
```

## Delete Product

> Deletes a subscription product. Products can be deleted via API or the iyzico merchant panel only when there are no plans linked to the product.

```json
{"openapi":"3.0.3","info":{"title":"Subscription Product","version":"1.0.0"},"tags":[{"name":"Subscription Product","description":"Subscription product management services."}],"servers":[{"url":"https://api.iyzipay.com","description":"iyzico API"}],"paths":{"/v2/subscription/products/{productReferenceCode}":{"delete":{"summary":"Delete Product","operationId":"deleteSubscriptionProduct","description":"Deletes a subscription product. Products can be deleted via API or the iyzico merchant panel only when there are no plans linked to the product.","tags":["Subscription Product"],"parameters":[{"$ref":"#/components/parameters/AuthHeader"},{"$ref":"#/components/parameters/ContentTypeHeader"},{"name":"productReferenceCode","in":"path","required":true,"schema":{"type":"string"},"description":"Unique reference code of the product."}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionProductDeleteSuccess"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}},"components":{"parameters":{"AuthHeader":{"name":"Authorization","in":"header","required":true,"description":"Authorization header; a signed hash value that starts with **IYZWSv2** and is generated in Base64 format.","schema":{"type":"string"}},"ContentTypeHeader":{"name":"Content-Type","in":"header","required":true,"description":"Content type of the request body.","schema":{"type":"string"}}},"schemas":{"SubscriptionProductDeleteSuccess":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."}}},"ErrorResponse":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"errorCode":{"type":"string","description":"Error code."},"errorMessage":{"type":"string","description":"Error message."},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."}}}}}}
```

## List Products

> Lists subscription products. Use this to fetch all products and their linked plans. To reduce latency and payload size, pagination is used so you can retrieve the product list page by page.

```json
{"openapi":"3.0.3","info":{"title":"Subscription Product","version":"1.0.0"},"tags":[{"name":"Subscription Product","description":"Subscription product management services."}],"servers":[{"url":"https://api.iyzipay.com","description":"iyzico API"}],"paths":{"/v2/subscription/products":{"get":{"summary":"List Products","operationId":"listSubscriptionProducts","description":"Lists subscription products. Use this to fetch all products and their linked plans. To reduce latency and payload size, pagination is used so you can retrieve the product list page by page.","tags":["Subscription Product"],"parameters":[{"$ref":"#/components/parameters/AuthHeader"},{"$ref":"#/components/parameters/ContentTypeHeader"}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionProductListRequest"}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionProductListSuccess"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}},"components":{"parameters":{"AuthHeader":{"name":"Authorization","in":"header","required":true,"description":"Authorization header; a signed hash value that starts with **IYZWSv2** and is generated in Base64 format.","schema":{"type":"string"}},"ContentTypeHeader":{"name":"Content-Type","in":"header","required":true,"description":"Content type of the request body.","schema":{"type":"string"}}},"schemas":{"SubscriptionProductListRequest":{"type":"object","properties":{"page":{"type":"integer","description":"Returns products for the specified page."},"count":{"type":"integer","description":"Number of products per page."}}},"SubscriptionProductListSuccess":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."},"data":{"type":"object","description":"Pagination results.","properties":{"totalCount":{"type":"string","description":"Total number of results returned."},"currentPage":{"type":"integer","description":"Page number returned."},"pageCount":{"type":"integer","description":"Total page count."},"items":{"type":"array","description":"Product list.","items":{"$ref":"#/components/schemas/ProductResource"}}}}}},"ProductResource":{"type":"object","description":"Product details.","properties":{"referenceCode":{"type":"string","description":"Unique reference code of the product."},"createdDate":{"type":"string","description":"Product creation date (`YYYY-MM-DD hh:mm:ss`)."},"name":{"type":"string","description":"Product name."},"description":{"type":"string","description":"Product description."},"status":{"type":"string","description":"Product status (default ACTIVE)."},"pricingPlans":{"type":"array","description":"List of plans linked to the product.","items":{"$ref":"#/components/schemas/PricingPlanBrief"}}}},"PricingPlanBrief":{"type":"object","description":"Summary view of the plan linked to the product.","properties":{"referenceCode":{"type":"string","description":"Unique reference code of the plan."},"createdDate":{"type":"string","description":"Plan creation date (`YYYY-MM-DD hh:mm:ss`)."},"name":{"type":"string","description":"Plan name."},"price":{"type":"decimal","description":"Plan price (Decimal)."},"paymentInterval":{"type":"string","enum":["WEEKLY","MONTHLY","DAILY","YEARLY"],"description":"Payment frequency."},"paymentIntervalCount":{"type":"integer","description":"Number of repeats for the payment interval."},"trialPeriodDays":{"type":"integer","description":"Trial period (days)."},"currencyCode":{"type":"string","description":"Currency (e.g., TRY)."},"productReferenceCode":{"type":"string","description":"Reference code of the product the plan belongs to."},"planPaymentType":{"type":"string","description":"Plan payment type (RECURRING)."},"status":{"type":"string","description":"Plan status (e.g., ACTIVE)."},"recurrenceCount":{"type":"integer","description":"Total number of recurrences (if any)."}}},"ErrorResponse":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"errorCode":{"type":"string","description":"Error code."},"errorMessage":{"type":"string","description":"Error message."},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."}}}}}}
```

## Get Product

> Retrieves details of a single product. Provide the product reference code in the request.

```json
{"openapi":"3.0.3","info":{"title":"Subscription Product","version":"1.0.0"},"tags":[{"name":"Subscription Product","description":"Subscription product management services."}],"servers":[{"url":"https://api.iyzipay.com","description":"iyzico API"}],"paths":{"/v2/subscription/products/{productReferenceCode}":{"get":{"summary":"Get Product","operationId":"getSubscriptionProduct","description":"Retrieves details of a single product. Provide the product reference code in the request.","tags":["Subscription Product"],"parameters":[{"$ref":"#/components/parameters/AuthHeader"},{"$ref":"#/components/parameters/ContentTypeHeader"},{"name":"productReferenceCode","in":"path","required":true,"schema":{"type":"string"},"description":"Unique reference code of the product."}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionProductGetSuccess"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}},"components":{"parameters":{"AuthHeader":{"name":"Authorization","in":"header","required":true,"description":"Authorization header; a signed hash value that starts with **IYZWSv2** and is generated in Base64 format.","schema":{"type":"string"}},"ContentTypeHeader":{"name":"Content-Type","in":"header","required":true,"description":"Content type of the request body.","schema":{"type":"string"}}},"schemas":{"SubscriptionProductGetSuccess":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."},"data":{"$ref":"#/components/schemas/ProductResource"}}},"ProductResource":{"type":"object","description":"Product details.","properties":{"referenceCode":{"type":"string","description":"Unique reference code of the product."},"createdDate":{"type":"string","description":"Product creation date (`YYYY-MM-DD hh:mm:ss`)."},"name":{"type":"string","description":"Product name."},"description":{"type":"string","description":"Product description."},"status":{"type":"string","description":"Product status (default ACTIVE)."},"pricingPlans":{"type":"array","description":"List of plans linked to the product.","items":{"$ref":"#/components/schemas/PricingPlanBrief"}}}},"PricingPlanBrief":{"type":"object","description":"Summary view of the plan linked to the product.","properties":{"referenceCode":{"type":"string","description":"Unique reference code of the plan."},"createdDate":{"type":"string","description":"Plan creation date (`YYYY-MM-DD hh:mm:ss`)."},"name":{"type":"string","description":"Plan name."},"price":{"type":"decimal","description":"Plan price (Decimal)."},"paymentInterval":{"type":"string","enum":["WEEKLY","MONTHLY","DAILY","YEARLY"],"description":"Payment frequency."},"paymentIntervalCount":{"type":"integer","description":"Number of repeats for the payment interval."},"trialPeriodDays":{"type":"integer","description":"Trial period (days)."},"currencyCode":{"type":"string","description":"Currency (e.g., TRY)."},"productReferenceCode":{"type":"string","description":"Reference code of the product the plan belongs to."},"planPaymentType":{"type":"string","description":"Plan payment type (RECURRING)."},"status":{"type":"string","description":"Plan status (e.g., ACTIVE)."},"recurrenceCount":{"type":"integer","description":"Total number of recurrences (if any)."}}},"ErrorResponse":{"type":"object","properties":{"status":{"type":"string","description":"Operation result.","enum":["success","failure"]},"errorCode":{"type":"string","description":"Error code."},"errorMessage":{"type":"string","description":"Error message."},"systemTime":{"type":"integer","description":"Operation time (epoch ms)."}}}}}}
```
