# 一意のクーポンコード制限を取得する

コードの残り使用可能回数を取得します。コードのフィルタリングには、codesクエリパラメータを使用します。

コードの上限を設定するには、管理セクションに移動します：
* クーポン

Endpoint: GET /v2/project/{project_id}/admin/code/limit/coupon/external_id/{external_id}
Version: 2.0.0
Security: basicAuth

## Path parameters:

  - `project_id` (integer, required)
    プロジェクトID。このパラメータは、パブリッシャーアカウントのプロジェクト名の横、またはプロジェクトの作業中にブラウザのアドレスバーで確認できます。URLの形式は以下の通りです：https://publisher.xsolla.com//projects/。
    Example: 44056

  - `external_id` (integer, required)
    プロモーションexternal ID。プロジェクト内での一意のプロモーション識別子。
    Example: "coupon_44056_1"

## Query parameters:

  - `codes[]` (array)
    大文字と小文字を区別する一意のコード。文字と数字のみを含めてください。

  - `limit` (integer)
    ページでの要素数の制限。
    Example: 50

  - `offset` (integer)
    リストが生成される要素番号（カウントは0から始まります）。

## Response 200 fields (application/json):

  - `promotion_id` (integer)
    プロモーションID。プロジェクト内での一意のプロモーション識別子。

  - `items` (array)

  - `items.code` (string)
    大文字と小文字を区別する一意のコードです。文字と数字が含まれます。

  - `items.per_code` (object)

  - `items.per_code.total` (integer)
    プロモーションコードの最大使用回数。

  - `items.per_code.available` (integer)
    プロモーションコードの残り使用可能回数。

  - `items.per_code.used` (integer)
    プロモーションコードの使用回数。

  - `items.per_code.reserved` (integer)
    プロモーションコードの予約回数。

  - `total_items_count` (number)
    コードの総数。

  - `has_more` (boolean)
    コードを含む別のページが存在する場合。

## Response 401 fields (application/json):

  - `statusCode` (integer)
    Example: 401

  - `errorCode` (integer)
    Example: 1020

  - `errorMessage` (string)
    Example: "[0401-1020]: Error in Authentication method occurred"

## Response 404 fields (application/json):

  - `statusCode` (integer)

  - `errorCode` (integer)

  - `errorMessage` (string)

  - `transactionId` (string)

## Response 422 fields (application/json):

  - `statusCode` (integer)

  - `errorCode` (integer)

  - `errorMessage` (string)

  - `errorMessageExtended` (array)


