# 1Password パートナーシップ API リファレンス

1Password パートナーシップ API を使うと、顧客向けのサードパーティ パートナーの請求アカウントのプロビジョニングとデプロビジョニングを管理できます。API は、1Password の個人アカウントとファミリー アカウントのパートナー請求アカウントをサポートしています。パートナーシップ API は、1Password チーム アカウントまたはビジネス アカウントをサポートしていません。

注記

別のツールで 1Password Partnership API を使うには、API 仕様ファイル[1password-partnership-api.yml](https://i.1password.com/media/1password-partnership-api/partnership-api.yml)をダウンロードします。

### **前提条件** <a href="#a5iwvvp09bys" id="a5iwvvp09bys"></a>

API を使用してパートナーの請求サービスと統合する前に、1Password パートナーとして登録する必要があります。登録されたパートナーには、API 請求サーバーへのリクエストを承認するためのベアラー トークンへのアクセス権が付与されます。

パートナーシップの機会について詳しくは、[1Password パートナー プログラムの Web サイト](https://www.1password.partners/)にアクセスするか、[1Password パートナーシップ チーム](mailto:partners@1password.com)にお問い合わせください。

### **APIに関する情報** <a href="#id-4yuhw0abwxdo" id="id-4yuhw0abwxdo"></a>

1Password パートナーシップ API は、 [OpenAPI 3.0 仕様](https://spec.openapis.org/oas/v3.0.3)に準拠した REST スタイルの API です。クライアントとサーバー間の全ての通信は HTTPS 経由で行われます。

パートナーシップ API のテストと実装には、お好みのプログラミング言語とツールを使用できます。このリファレンスでは、コマンド ラインで[curl ](https://curl.se/)を使用してサンプル リクエストを示します。リクエスト内の値を独自の値に置き換えて、顧客の請求アカウントに関する情報を受け取ることができます。

#### **Request methods** <a href="#vltxne8kyjrf" id="vltxne8kyjrf"></a>

次の標準 HTTP メソッドを使用して、Partnership API にリクエストを送信できます。

* [POST](https://developer.1password.com/docs/partnership-api/reference/#create-a-billing-account) : パートナーの請求サービスを通じて顧客のサードパーティの請求アカウントをCreateします。
* [GET](https://developer.1password.com/docs/partnership-api/reference/#get-billing-account-information) : 顧客の請求アカウントの詳細を取得します。
* [DELETE](https://developer.1password.com/docs/partnership-api/reference/#delete-a-billing-account) : パートナーの請求サービスから顧客のサードパーティの請求アカウントを削除します。
* [パッチ](https://developer.1password.com/docs/partnership-api/reference/#update-a-billing-account-end-date): 顧客の請求アカウントがパートナーの請求サービスから削除される予定の日時を更新します。

バッチリクエストはサポートされていません。

#### **Servers**[**​**](https://developer.1password.com/docs/partnership-api/reference/#servers) <a href="#id-5gzgtaaytcd3" id="id-5gzgtaaytcd3"></a>

パートナーが 1Password Partnership API を操Createするために使用できる課金サーバーには、API エンドポイントのベース URL を提供するものが 2 つあります。

* **Test server**( <https://billing.b5test.eu>): テスト環境内の全てのリクエストのベースとしてテスト サーバーの URL を使用します。テスト サーバー ( **b5test.com、b5test.ca、b5test.eu**)から、全てのドメインのテスト パートナー課金アカウントをプロビジョニングおよびプロビジョニング解除できます。
* **Production server**( <https://billing.1password.com>): 運用環境の全てのリクエストのベースとして運用サーバーの URL を使用します。運用サーバーから、全てのドメイン ( **1password.com、1password.ca**、および**1password.eu** ) のパートナー課金アカウントをプロビジョニングおよびプロビジョニング解除できます。

#### **Endpoints**[**​**](https://developer.1password.com/docs/partnership-api/reference/#endpoints) <a href="#g5zxpi34wf4v" id="g5zxpi34wf4v"></a>

API への各リクエストは、操Createするサーバー環境 (テストまたは本番) のベース URL で始まり、その後にパス ( api/v1/partners/account) が続きます。中括弧 ( {}) で示されるパス パラメータは、定義されている場合に必須です。例:

APIエンドポイントの構造

①\<base\_URL>/②\<path>/③{parameters}

①base\_URLと③{parameters}プレースホルダーを、使用しているサーバー環境とリクエストに指定されたパス パラメータに置き換えます。②pathは全てのリクエストで同じです。

パスパラメータのない API エンドポイントの例

①<https://billing.b5test.eu/②api/v1/partners/accounts>

パスパラメータを持つ API エンドポイントの例

①<https://billing.1password.com/②api/v1/partners/accounts/③4266474b-6385-56d4-7b75-648096593064>

#### **Authorization** <a href="#id-21pi5v10fb9" id="id-21pi5v10fb9"></a>

[1Password パートナー プログラム](https://www.1password.partners/)に登録すると、パートナーシップ チームから、パートナーシップ API への呼び出しを承認するために必要なベアラー トークンが提供されます。

[テスト環境と本番環境](https://developer.1password.com/docs/partnership-api/reference/#servers)で使うトークンが別々に提供されます。Create業している環境で承認されたトークンを必ず使用してください。

いずれかの環境で新しいベアラー トークンが必要な場合は、[1Password パートナーシップ チームにお問い合わせください。](mailto:partners@1password.com)

#### **リクエストヘッダー** <a href="#ja7jpkj4w1w8" id="ja7jpkj4w1w8"></a>

パートナーシップ API へのリクエストでは、次の 3 種類のヘッダーが使用されます。

* Authorization: パートナーシップ API への各 GET、POST、DELETE、および PATCH リクエストは、[ベアラー トークン](https://developer.1password.com/docs/partnership-api/reference/#authorization)を使用して承認される必要があります。
* Content-Type: 各 POST および PATCH リクエストには、リクエスト本体のメディア (MIME) タイプを示すヘッダーが必要です。
* Accept: Partnership API への各 GET、POST、および PATCH リクエストには、クライアントがサーバーから受け入れることができる応答の種類を示す accept ヘッダーを含める必要があります。

全てのデータは JSON として送受信されるため、ヘッダーでそのことを必ず指定してください。

Authorization: Bearer YOUR\_BEARER\_TOKEN

Content-type: application/json

Accept: application/json

[ベアラートークン](https://developer.1password.com/docs/partnership-api/reference/#authorization)をお持ちでない場合、またはinvalid auth tokenAPI へのリクエスト時にエラーが発生した場合は、1Password パートナーシップ チームにお問い合わせください。

#### **リクエストボディ** <a href="#id-92usabecn0zp" id="id-92usabecn0zp"></a>

リクエスト ボディ (リクエスト ペイロードとも呼ばれます) には、サーバー上のリソースをCreate (POST) または更新 (PATCH) するためにクライアントが送信する JSON 形式のデータが含まれます。リクエスト ボディは、次に示すように、1 つ以上のフィールドを含むオブジェクトで構成されます。

* **顧客の請求先アカウントの一意の識別子 (UID)**。UID はパートナーによって提供されます。英数字とハイフンの任意の組み合わせで最大 80 文字まで指定できます。
* **1Password アカウントの種類**。オプションは個人 (I) または家族 (F) です。チーム アカウントとビジネス アカウントはサポートされていません。
* **顧客が新規または保存済みの 1Password アカウントに使用できるドメイン**。テスト サーバーの場合、オプションは b5test.com、b5test.ca、または b5test.eu です。実稼働サーバーの場合、オプションは 1password.com、1password.ca、または 1password.eu です。
* **顧客の請求アカウントを削除する予定の日時**。日付は過去の日付にすることはできません。日付、時刻、およびオプションのタイムゾーンは、[ISO 8601 標準](https://www.iso.org/iso-8601-date-and-time-format.html)に従ってフォーマットします。

GET および DELETE 呼び出しにはリクエスト本体は含まれません。

#### **アクティベーショントークン** <a href="#id-6hqdj5f2ir0v" id="id-6hqdj5f2ir0v"></a>

アクティベーション トークンは、1Password アカウントをパートナーの請求アカウントにリンクすることで、顧客にサードパーティの請求をプロビジョニングするために使用されます。

パートナーシップ API に[POST call](https://developer.1password.com/docs/partnership-api/reference/#create-a-billing-account)を行って、顧客の新しいパートナー請求アカウントをCreateし、固有のアクティベーション トークンを生Createします。

[POST レスポンス](https://developer.1password.com/docs/partnership-api/reference/#success-response)で返されたトークンを1Password パートナーシップ引き換えリンクに追加して、[顧客のパートナー請求リンクをCreateします](https://developer.1password.com/docs/partnership-api/reference/#create-a-link-for-customers)。次に、顧客にリンクを提供します。

リンクをクリックすると、顧客はプロモーション ページに移動し、新しい 1Password アカウントをCreateするか、保存済みのアカウントにサインインするように指示されます。顧客の 1Password アカウントの請求は、パートナーの請求アカウントにリンクされます。

**顧客向けリンクをCreateする**

顧客のパートナー請求リンクをCreateするには、1Password パートナーシップ引き換えリンク (<https://start.\\[1password\\_domain]/partnership/redeem>) を調整して、目的の 1Password ドメインを使用します。次に、アカウント タイプとアクティベーション トークンに必要なパラメーターを含むクエリ文字列を追加します。オプションの[言語パラメータ](https://developer.1password.com/docs/partnership-api/reference/#language-codes)を含めることもできます。

1Password アカウントのパートナー請求リンクの構造

<https://start.\\[1password\\_domain]/partnership/redeem?t={account\\_type}\\&c={activation\\_token}\\&l={language\\_code}>

| **プレースホルダー**         | **価値観**                                                                                                                                                         | **必須** |
| -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------ |
| \[1password\_domain] | 可能な値は1password.com、、1password.caまたはです1password.eu。                                                                                                              | はい     |
| {account\_type}      | 可能な値はindividualまたは ですfamily。                                                                                                                                    | はい     |
| {activation\_token}  | [POST 応答](https://developer.1password.com/docs/partnership-api/reference/#success-response)で返されるトークンの値。例: 4266474b-6385-56d4-7b75-648096593064。                 | はい     |
| {language\_code}     | オプションの[言語](https://developer.1password.com/docs/partnership-api/reference/#language-codes)コードの値は en, de, es, fr, it, ja, ko, nl, pt-BR, ru, zh-Hans, zh-Hantです。 | いいえ    |

1Password ドメインのプレースホルダーとパラメータを適切な値に置き換えます。例:

オプションの言語パラメータを持つ 1Password.eu の個人アカウントのパートナー請求リンクの例

<https://start.1password.eu/partnership/redeem?t=individual\\&c=4266474b-6385-56d4-7b75-648096593064\\&l=de>

オプションの言語パラメータを持つ 1Password.com のファミリー アカウントのパートナー請求リンクの例

<https://start.1password.com/partnership/redeem?t=family\\&c=4266474b-6385-56d4-7b75-648096593064\\&l=en>

どのリンクをCreateする必要があるかわからない場合は、[1Password パートナーシップ チームにお問い合わせください。](mailto:partners@1password.com)

注意

保存済みの 1Password アカウントを持つお客様の場合、パートナーの請求リンクは、1Password アカウントの種類とドメインが[POST リクエスト](https://developer.1password.com/docs/partnership-api/reference/#request)で指定されたものと同じである場合にのみ機能します。

保存済み[のアカウントの種類](https://support.1password.com/change-account-type/)や[地域](https://support.1password.com/regions/#change-your-region)を変更する際にサポートが必要な場合は、[1Password サポートにお問い合わせ](https://support.1password.com/contact/)ください。

**Alternate partner billing link options**

**代替リンク オプションの詳細をご覧ください。**

**パートナーシップ API は、パートナーの請求リンクの代替オプションもいくつかサポートしています。パートナーシップの詳細に応じて、次のリンクをCreateすることをお勧めします。**

[**新しい1Passwordアカウントのみ**](https://developer.1password.com/docs/partnership-api/reference/#create-a-link-for-a-new-1password-account-only)

**保存済み**[**の1Passwordアカウントのみ**](https://developer.1password.com/docs/partnership-api/reference/#create-a-link-for-an-existing-1password-account-only)

**これらのリンクのいずれかを顧客に提供した場合、顧客はそれを使用して、パートナーの請求先アカウントをそれぞれ新しいアカウントまたは保存済みのアカウントにリンクすることのみが可能になります。**

**また、各タイプのリンクを 1 つずつCreateし、顧客に両方を提供して、必要なオプションを選択できるようにすることもできます。ただし、両方のオプションを可能にする**[**単一のリンク**](https://developer.1password.com/docs/partnership-api/reference/#create-a-link-for-customers)**をCreateする方が、より良い解決策となる場合があります。**

**新しい 1Password アカウント**

**顧客が新しい 1Password アカウントでのみ使用できるパートナー請求リンクをCreateするには、1Password サインアップ リンク ( <https://start.\\[1password\\_domain]/sign-up/\\[account\\_type>]) を調整して、希望する 1Password ドメインとアカウント タイプを使用します。次に、必要なアクティベーション トークン パラメータを含むクエリ文字列を追加します。オプションの**[**言語パラメータ**](https://developer.1password.com/docs/partnership-api/reference/#language-codes)**を含めることもできます。例:**

**新しい 1Password アカウントのパートナー請求リンクの構造**

<https://start.\\[1password\\_domain]/sign-up/\\[account\\_type]?c={activation\\_token}\\&l={language\\_code}>

[1Password ドメイン、アカウント タイプ、およびパラメータのプレースホルダーを](https://developer.1password.com/docs/partnership-api/reference/#placeholder-reference)適切な値に置き換えます。例:

オプションの言語パラメータを持つ 1Password.eu の新規個人アカウントのパートナー請求リンクの例

<https://start.1password.eu/sign-up/individual?c=4266474b-6385-56d4-7b75-648096593064\\&l=de>

オプションの言語パラメータを含む 1Password.com の新しいファミリー アカウントのパートナー請求リンクの例

<https://start.1password.com/sign-up/family?c=4266474b-6385-56d4-7b75-648096593064\\&l=en>

保存済みの 1Password アカウントのみのリンクをCreateします

保存済みの 1Password アカウントでのみ顧客が使用できるパートナー請求リンクをCreateするには、1Password アカウントのサインイン リンク ( <https://my.\\[1password\\_domain]/partnership/link>) を調整して、目的の 1Password ドメインを使用します。次に、必要なアクティベーション トークン パラメータを含むクエリ文字列を追加します。オプションの[言語パラメータ](https://developer.1password.com/docs/partnership-api/reference/#language-codes)を含めることもできます。例:

保存済みの 1Password アカウントのパートナー請求リンクの構造

<https://my.\\[1password\\_domain]/partnership/link?c={activation\\_token}\\&l={language\\_code}>

[1Password ドメインのプレースホルダー](https://developer.1password.com/docs/partnership-api/reference/#placeholder-reference)とパラメータを適切な値に置き換えます。例:

オプションの言語パラメータを持つ 1Password.com の保存済みアカウントのパートナー請求リンクの例

<https://my.1password.com/partnership/link?c=4266474b-6385-56d4-7b75-648096593064\\&l=en>

このリンクにはアカウントの種類は含まれません。顧客が既に持っている 1Password アカウントにサインインするように指示するためです。

**プレースホルダー**[**参照**](https://developer.1password.com/docs/partnership-api/reference/#placeholder-reference)

| **プレースホルダー**         | **価値観**                                                                                                                                                                                               | **必須**                    |
| -------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------- |
| \[1password\_domain] | 可能な値は1password.com、、1password.caまたは1password.euです。                                                                                                                                                    | はい                        |
| \[account\_type]     | アカウント タイプは、[新しい 1Password アカウントをCreateする](https://developer.1password.com/docs/partnership-api/reference/#create-a-link-for-a-new-1password-account-only)ためのリンクでのみ使用されます。可能な値はindividualまたはfamily です。 | <p>はい</p><p>新規アカウントのみ</p> |
| {activation\_token}  | [POST 応答](https://developer.1password.com/docs/partnership-api/reference/#success-response)で返されるトークンの値。例: 4266474b-6385-56d4-7b75-648096593064。                                                       | はい                        |
| {language\_code}     | オプションの[言語](https://developer.1password.com/docs/partnership-api/reference/#language-codes)コードの値はen, de, es, fr, it, ja, ko, nl, pt-BR, ru, zh-Hans, またはzh-Hantです。                                     | いいえ                       |

**言語コード**

オプションの言語コード パラメータの詳細について説明します。

[言語コードは、パートナーの請求リンク](https://developer.1password.com/docs/partnership-api/reference/#create-a-link-for-customers)に追加できるオプションのパラメータで、顧客をその言語の適切なランディング ページに誘導します。言語パラメータが含まれていない場合、顧客はデフォルトのランディング ページ (英語) に誘導されます。

言語パラメータでは次の言語コードを使用できます。

| 0UkVhO3HLLeq | zuyO4aP6oj8K |
| ------------ | ------------ |
| **言語**       | **コード**      |
| 英語           | en           |
| ドイツ語         | de           |
| スペイン語        | es           |
| フランス語        | fr           |
| イタリア語        | it           |
| 日本語          | ja           |
| **言語**       | **コード**      |
| 韓国語          | ko           |
| オランダ語        | nl           |
| ポルトガル語       | pt-BR        |
| ロシア語         | ru           |
| 簡体字          | zh-Hans      |
| 繁體中文         | zh-Hant      |

| **言語** | **コード** |
| ------ | ------- |
| 韓国語    | ko      |
| オランダ語  | nl      |
| ポルトガル語 | pt-BR   |
| ロシア語   | ru      |
| 簡体字    | zh-Hans |
| 繁體中文   | zh-Hant |

| **言語** | **コード** |
| ------ | ------- |
| 英語     | en      |
| ドイツ語   | de      |
| スペイン語  | es      |
| フランス語  | fr      |
| イタリア語  | it      |
| 日本語    | ja      |

### **請求先** <a href="#r43xu4e67m0c" id="r43xu4e67m0c"></a>

POST \<base\_URL>/api/v1/partners/accounts

POST 呼び出しは、パートナー請求サービスを通じて顧客の新しいサードパーティ請求アカウントをCreateし、顧客がプロビジョニングを完了するためのパートナー請求リンクをCreateするために使う[アクティベーション トークンを返します。](https://developer.1password.com/docs/partnership-api/reference/#activation-tokens)

#### **パス** <a href="#uckzapu1lea3" id="uckzapu1lea3"></a>

パスパラメータがありません。

[ベアラー トークン](https://developer.1password.com/docs/partnership-api/reference/#authorization)と必要な[リクエスト ヘッダーを](https://developer.1password.com/docs/partnership-api/reference/#request-headers)含むエンドポイント URL を使用します。次の内容を含むオブジェクトを[リクエスト本文として含めます。](https://developer.1password.com/docs/partnership-api/reference/#request-bodies)

* 顧客のアカウント UID。
* 適格な 1Password アカウントの種類。
* 顧客が新規または保存済みの 1Password アカウントに使用できるドメイン。
* (オプション) パートナーの請求サービスから顧客のアカウントを削除する日時。この値は過去のものにすることはできません。PATCH[リクエスト](https://developer.1password.com/docs/partnership-api/reference/#update-a-billing-account-end-date)を使用してこのフィールドを更新することもできます。

**Example request**

curl --request POST \\

\--url <https://billing.1password.com/api/v1/partners/accounts> \\

\--header 'Authorization: Bearer YOUR\_BEARER\_TOKEN' \\

\--header 'Content-Type: application/json' \\

\--header 'Accept: application/json' \\

\--data '{

"customer\_account\_uid": "4266474b-6385-56d4-7b75-648096593064",

"account\_type": "F",

"domain": "1password.com",

"ends\_at": "2024-08-31T13:00:00-05:00"

}'

**Request object schema**

| **名前**                                                                   | **タイプ** | **説明**                                                                                                                                                      |
| ------------------------------------------------------------------------ | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <p><strong>customer\_account\_uid</strong></p><p><strong>必須</strong></p> | string  | 顧客の請求アカウントの一意の識別子 (UID)。UID は、英数字とハイフンの任意の組み合わせで最大 80 文字まで指定できます。                                                                                           |
| <p><strong>account\_type</strong></p><p><strong>必須</strong></p>          | string  | 顧客にプロビジョニングする 1Password アカウントの種類:I個人アカウントまたはFファミリー アカウント。チーム アカウントとビジネス アカウントはサポートされていません。                                                                  |
| <p><strong>domain</strong></p><p><strong>必須</strong></p>                 | string  | 顧客がパートナーの課金サービスで使用できる新規または保存済みの 1Password アカウントのドメイン。テスト サーバーの場合: b5test.com、b5test.ca、またはb5test.eu。実稼働サーバーの場合: 1password.com、1password.ca、または1password.eu。 |
| **ends\_at**                                                             | string  | 顧客の請求アカウントがパートナーの請求サービスから削除される予定の日時。RFC 3339 で定義された形式を使用します。                                                                                                |

#### Create**功レスポンス** <a href="#z5cntokthbgn" id="z5cntokthbgn"></a>

201応答では、顧客の 1Password アカウントをパートナーの請求アカウントにリンクするために使用される一意の[アクティベーション トークン](https://developer.1password.com/docs/partnership-api/reference/#activation-tokens)を含む Account オブジェクトが返されます。

**Example response**

{

"customer\_account\_uid": "4266474b-6385-56d4-7b75-648096593064",

"account\_type": "F",

"activation\_token": "PNS-D5A75BT2",

"domain": "1password.com",

"status": "entitled",

"deployed\_members": 0,

"created\_at": "2023-08-24T04:19:44Z",

"updated\_at": "2023-09-15T15:58:22Z",

"ends\_at": "2024-08-31T18:00:00Z"

}

**Response object schema**

| **名前**                     | **タイプ** | **説明**                                                                                                                                                                                                                                                                                                                                                                                          |
| -------------------------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **customer\_account\_uid** | string  | 顧客の請求アカウントの一意の識別子 (UID)。UID は、英数字とハイフンの任意の組み合わせで最大 80 文字まで指定できます。                                                                                                                                                                                                                                                                                                                               |
| **account\_type**          | string  | 顧客用にプロビジョニングした 1Password アカウントの種類:I個人アカウント用またはFファミリー アカウント用。                                                                                                                                                                                                                                                                                                                                    |
| **activation\_token**      | string  | 顧客の新規または保存済みの 1Password アカウントをパートナーの請求先アカウント (例: ) に接続するリンクをCreateするために使う[アクティベーション トークン](https://developer.1password.com/docs/partnership-api/reference/#activation-tokens)。<https://start.\\[1password\\_domain]/partnership/redeem?t=\\[account\\_type]\\&c=\\[activation\\_token]\\&l=\\[language\\_code]トークンは> 1Password の個人アカウントまたはファミリー アカウントでのみ使用できます。チーム アカウントとビジネス アカウントはサポートされていません。 |
| **domain**                 | string  | 顧客がパートナーの課金サービスで使用できる新規または保存済みの 1Password アカウントのドメイン。テスト サーバーの場合: b5test.com、b5test.ca、またはb5test.eu。実稼働サーバーの場合: 1password.com、1password.ca、または1password.eu。                                                                                                                                                                                                                                     |
| **status**                 | string  | <p>プロビジョニングされた顧客請求アカウントのステータス。可能な値は次のいずれかです。</p><ul><li>entitledプロビジョニングは開始されましたが、顧客は新規または保存済みの 1Password アカウントでパートナーの請求リンクを使用していません。</li><li>provisioned顧客は新規または保存済みの 1Password アカウントでパートナーの請求リンクを使用し、サードパーティの請求アカウントがプロビジョニングされています。</li></ul><p>POST リクエストの期待値は entitledです。</p>                                                                                                              |
| **deployed\_members**      | integer | <p>1Password アカウントにプロビジョニングされたユーザーの数。POST</p><p>リクエストに対して返される予想値は 0です。</p>                                                                                                                                                                                                                                                                                                                      |
| **created\_at**            | string  | 顧客の請求アカウントがCreateされた日時。ISO [8601 標準](https://www.iso.org/iso-8601-date-and-time-format.html)を使用します。                                                                                                                                                                                                                                                                                             |
| **updated\_at**            | string  | <p>請求先アカウントが最後に更新された日時。ISO <a href="https://www.iso.org/iso-8601-date-and-time-format.html">8601 標準</a>を使用します。このフィールドは、アカウントのステータスが変更されたときに更新されます。POST</p><p>リクエストに対して返される予想値は、created\_atプロパティの値と同じです。</p>                                                                                                                                                                                     |
| **ends\_at**               | string  | 顧客の請求アカウントがパートナーの請求サービスから削除される予定の日時。ISO [8601 標準](https://www.iso.org/iso-8601-date-and-time-format.html)を使用します。日時が指定されていない場合、期待値は nullです。                                                                                                                                                                                                                                                      |

#### **エラー応答** <a href="#id-5zezl1j9gbey" id="id-5zezl1j9gbey"></a>

400不正なリクエストで返されました。

**Example error**

{

"code": 400,

"error": "bad\_request",

"description": "Account type B is not supported."

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

403リクエスト本文に認証ヘッダーがない場合、または無効なトークンが指定された場合に返されます。

**Example error**

{

"code": 403,

"error": "forbidden",

"description": "Invalid auth token."

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

404リソースまたはリソースの依［Save］関係が見つからない場合に返されます。

**Example error**

{

"code": 404,

"error": "not\_found",

"description": "Domain not found."

}

**Error object schema**

| **パラメータ**       | **タイプ**     | **説明**                  |
| --------------- | ----------- | ----------------------- |
| **code**        | **integer** | **エラーの HTTP 応答コード。**    |
| **error**       | **string**  | **コードを表す、機械で解析可能な文字列。** |
| **description** | **string**  | **エラーの説明。**             |

500予期しないエラーが発生した場合に返されます。

**Example error**

{

"code": 500,

"error": "internal\_server\_error",

"description": "Internal server error"

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

### **請求先アカウント情報** <a href="#iusezsiq74a3" id="iusezsiq74a3"></a>

GET \<base\_URL>/api/v1/partners/accounts/{customer\_account\_uid}

GET 呼び出しは、顧客の請求アカウントに関する情報を取得します。パス パラメータとして顧客のアカウント UID を必ず含めてください。

#### **パスパラメータ** <a href="#id-8k19max0656f" id="id-8k19max0656f"></a>

| **パラメータ**                                                                | **タイプ** | **説明**             |
| ------------------------------------------------------------------------ | ------- | ------------------ |
| <p><strong>customer\_account\_uid</strong></p><p><strong>必須</strong></p> | string  | 顧客の請求アカウントの一意の ID。 |

#### **リクエスト** <a href="#id-1ol8gi4wqiw0" id="id-1ol8gi4wqiw0"></a>

[ベアラー トークン](https://developer.1password.com/docs/partnership-api/reference/#authorization)と必要な[リクエスト ヘッダーを](https://developer.1password.com/docs/partnership-api/reference/#request-headers)含むエンドポイント URL を使用して、顧客の課金アカウント情報をリクエストします。GET リクエストには本文が含まれていないため、Content-typeヘッダーは使用されません。

**Example request**

curl --request GET \\

\--url <https://billing.1password.com/api/v1/partners/accounts/{customer\\_account\\_uid}> \\

\--header 'Authorization: Bearer YOUR\_BEARER\_TOKEN' \\

\--header 'Accept: application/json'

#### Create**功レスポンス** <a href="#taeeky8s8iwa" id="taeeky8s8iwa"></a>

応答200では、顧客のサードパーティの請求アカウントに関する情報を提供する Account オブジェクトが返されます。

**Example response**

{

"customer\_account\_uid": "4266474b-6385-56d4-7b75-648096593064",

"account\_type": "F",

"activation\_token": "PNS-D5A75BT2",

"domain": "1password.com",

"status": "provisioned",

"deployed\_members": 1,

"created\_at": "2023-08-24T04:19:44Z",

"updated\_at": "2023-09-15T15:58:22Z",

"ends\_at": "2024-08-31T18:00:00Z"

}

**Response object schema**

| **前**                      | **タイプ** | **説明**                                                                                                                                                                                                                                                                                                                                                                                          |
| -------------------------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **customer\_account\_uid** | string  | 顧客の請求アカウントの一意の識別子 (UID)。UID は、英数字とハイフンの任意の組み合わせで最大 80 文字まで指定できます。                                                                                                                                                                                                                                                                                                                               |
| **account\_type**          | string  | 顧客用にプロビジョニングした 1Password アカウントの種類:I個人アカウント用またはFファミリー アカウント用。                                                                                                                                                                                                                                                                                                                                    |
| **activation\_token**      | string  | 顧客の新規または保存済みの 1Password アカウントをパートナーの請求先アカウント (例: ) に接続するリンクをCreateするために使う[アクティベーション トークン](https://developer.1password.com/docs/partnership-api/reference/#activation-tokens)。<https://start.\\[1password\\_domain]/partnership/redeem?t=\\[account\\_type]\\&c=\\[activation\\_token]\\&l=\\[language\\_code]トークンは> 1Password の個人アカウントまたはファミリー アカウントでのみ使用できます。チーム アカウントとビジネス アカウントはサポートされていません。 |
| **domain**                 | string  | 顧客がパートナーの課金サービスで使用できる新規または保存済みの 1Password アカウントのドメイン。テスト サーバーの場合: b5test.com、b5test.ca、またはb5test.eu。実稼働サーバーの場合: 1password.com、1password.ca、または1password.eu。                                                                                                                                                                                                                                     |
| **status**                 | string  | <p>プロビジョニングされた顧客請求アカウントのステータス。可能な値は次のいずれかです。</p><ul><li>entitledプロビジョニングは開始されましたが、顧客は新規または保存済みの 1Password アカウントでパートナーの請求リンクを使用していません。</li><li>provisioned顧客は新規または保存済みの 1Password アカウントでパートナーの請求リンクを使用し、サードパーティの請求アカウントがプロビジョニングされています。</li></ul>                                                                                                                                                |
| **deployed\_members**      | integer | 1Password アカウントにプロビジョニングされたユーザーの数。                                                                                                                                                                                                                                                                                                                                                              |
| **created\_at**            | string  | 顧客の請求アカウントがCreateされた日時。ISO [8601 標準](https://www.iso.org/iso-8601-date-and-time-format.html)を使用します。                                                                                                                                                                                                                                                                                             |
| **updated\_at**            | string  | 顧客の請求先アカウントが最後に更新された日時。ISO [8601 標準](https://www.iso.org/iso-8601-date-and-time-format.html)を使用します。このフィールドは、アカウントのステータスが変更されると更新されます。                                                                                                                                                                                                                                                           |
| **ends\_at**               | string  | 顧客の請求アカウントがパートナーの請求サービスから削除される予定の日時。ISO [8601 標準](https://www.iso.org/iso-8601-date-and-time-format.html)を使用します。日時が指定されていない場合、期待値は nullです。                                                                                                                                                                                                                                                      |

#### **エラー応答** <a href="#id-6qmn94fsal1y" id="id-6qmn94fsal1y"></a>

403認証ヘッダーが欠落しているか、無効なトークンが指定された場合に返されます。

**Example error**

{

"code": 403,

"error": "forbidden",

"description": "Invalid auth token."

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

404リソースまたはリソースの依［Save］関係が見つからない場合に返されます。

**Example error**

{

"code": 404,

"error": "not\_found",

"description": "Failed to find the requested account."

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

410リソースが削除されたときに返されます。

**Example error**

{

"code": 410,

"error": "gone",

"description": "The requested account is gone."

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

500予期しないエラーが発生した場合に返されます。

**Example error**

{

"code": 500,

"error": "internal\_server\_error",

"description": "Internal server error"

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

### **請求先アカウントを削除** <a href="#id-1th8xu4rfn9n" id="id-1th8xu4rfn9n"></a>

DELETE \<base\_URL>/api/v1/partners/accounts/{customer\_account\_uid}

DELETE 呼び出しは、パートナーの課金サービスから顧客のサードパーティ課金アカウントを削除します。パス パラメータとして顧客のアカウント UID を必ず含めてください。

#### **パスパラメータ** <a href="#u9o3srgd359b" id="u9o3srgd359b"></a>

| **パラメータ**                                                                | **タイプ** | **説明**                |
| ------------------------------------------------------------------------ | ------- | --------------------- |
| <p><strong>customer\_account\_uid</strong></p><p><strong>必須</strong></p> | string  | 削除する顧客請求アカウントの一意の ID。 |

#### **リクエスト** <a href="#id-9h5nad1cgq21" id="id-9h5nad1cgq21"></a>

顧客の請求先アカウントを削除するには、必要な[リクエスト ヘッダーに](https://developer.1password.com/docs/partnership-api/reference/#request-headers)[ベアラー トークン](https://developer.1password.com/docs/partnership-api/reference/#authorization)を含むエンドポイント URL を使用します。DELETE リクエストとそれに続く応答には本文が含まれていないため、Content-typeおよびAcceptヘッダーは使用されません。

**Example request**

curl --request DELETE \\

\--url <https://billing.1password.com/api/v1/partners/accounts/{customer\\_account\\_uid}> \\

\--header 'Authorization: Bearer YOUR\_BEARER\_TOKEN' \\

#### Create**功レスポンス** <a href="#vhvy2ajukww4" id="vhvy2ajukww4"></a>

顧客請求アカウントの非アクティブ化と削除が正常に完了すると、204応答が返されます。請求アカウントが削除されたため、GET 要求では顧客アカウント UID のアカウント情報は返されなくなります。

#### **エラー応答** <a href="#vixsu9e8udon" id="vixsu9e8udon"></a>

403認証ヘッダーが欠落しているか、無効なトークンが指定された場合に返されます。

**Example error**

{

"code": 403,

"error": "forbidden",

"description": "Invalid auth token."

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

404リソースまたはリソースの依［Save］関係が見つからない場合に返されます。

**Example value**

{

"code": 404,

"error": "not\_found",

"description": "Failed to find the requested account."

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

500予期しないエラーが発生した場合に返されます。

**Example error**

{

"code": 500,

"error": "internal\_server\_error",

"description": "Internal server error"

}

**Error object schema**

| **パラメータ**       | **タイプ** | **説明**              |
| --------------- | ------- | ------------------- |
| **code**        | integer | エラーの HTTP 応答コード。    |
| **error**       | string  | コードを表す、機械で解析可能な文字列。 |
| **description** | string  | エラーの説明。             |

### **請求先アカウントの終了日** <a href="#pndy43swrohx" id="pndy43swrohx"></a>

PATCH \<base\_URL>/api/v1/partners/accounts/{customer\_account\_uid}

PATCH 呼び出しを使うと、顧客の請求先アカウントの終了日を追加、編集、または削除できます。パス パラメータとして顧客のアカウント UID を必ず含めてください。

#### **パスパラメータ** <a href="#mnjv2dt642nb" id="mnjv2dt642nb"></a>

| **パラメータ**                                                                | **タイプ** | **説明**             |
| ------------------------------------------------------------------------ | ------- | ------------------ |
| <p><strong>customer\_account\_uid</strong></p><p><strong>必須</strong></p> | string  | 顧客の請求アカウントの一意の ID。 |

#### **リクエスト** <a href="#vmqd0b1qfj7k" id="vmqd0b1qfj7k"></a>

[ベアラー トークン](https://developer.1password.com/docs/partnership-api/reference/#authorization)と必要な[リクエスト ヘッダー](https://developer.1password.com/docs/partnership-api/reference/#request-headers)を含むエンドポイント URL を使用します。フィールドを含むオブジェクトを[リクエスト ボディ](https://developer.1password.com/docs/partnership-api/reference/#request-bodies)ends\_atとして含めます。

顧客の請求アカウントをパートナーシップ請求サービスから削除する予定の日時を追加または更新するには、RFC 3339 で定義された形式で、新しい日時をends\_at値として含めます。

顧客の請求先アカウントから終了日時を削除するには、値として空の文字列 ( "") またはnullを使用します。

**Example request**

curl --request PATCH \\

\--url <https://billing.1password.com/api/v1/partners/accounts/{customer\\_account\\_uid}> \\

\--header 'Authorization: Bearer YOUR\_BEARER\_TOKEN' \\

\--header 'Accept: application/json' \\

\--data '{

"ends\_at": "2024-08-31T13:00:00-05:00"

}'

**Request object schema**

| **名前**                                                     | **タイプ**    | **説明**                                                                                                           |
| ---------------------------------------------------------- | ---------- | ---------------------------------------------------------------------------------------------------------------- |
| <p><strong>ends\_at</strong></p><p><strong>必須</strong></p> | **string** | **顧客の課金アカウントがパートナー課金サービスから削除される予定の日時。RFC 3339 で定義された形式を使用します。アカウントから終了日を削除する場合は、値として空の文字列 ( "") またはnullを使用します。** |

#### **Create功レスポンス** <a href="#ud31jjqrw18s" id="ud31jjqrw18s"></a>

応答200では、請求アカウントに追加、編集、または削除された終了日など、顧客のサードパーティ請求アカウントに関する情報を提供する Account オブジェクトが返されます。

**Example response**

{

"customer\_account\_uid": "4266474b-6385-56d4-7b75-648096593064",

"account\_type": "F",

"activation\_token": "PNS-D5A75BT2",

"domain": "1password.com",

"status": "provisioned",

"deployed\_members": 1,

"created\_at": "2023-08-24T04:19:44Z",

"updated\_at": "2023-09-15T15:58:22Z",

"ends\_at": "2024-08-31T18:00:00Z"

}

**Response object schema**

| **名前**                     | **タイプ** | **説明**                                                                                                                                                                                                                                                                                                                                                                                          |
| -------------------------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **customer\_account\_uid** | string  | 顧客の請求アカウントの一意の識別子 (UID)。UID は、英数字とハイフンの任意の組み合わせで最大 80 文字まで指定できます。                                                                                                                                                                                                                                                                                                                               |
| **account\_type**          | string  | 顧客用にプロビジョニングした 1Password アカウントの種類:I個人アカウント用またはFファミリー アカウント用。                                                                                                                                                                                                                                                                                                                                    |
| **activation\_token**      | string  | 顧客の新規または保存済みの 1Password アカウントをパートナーの請求先アカウント (例: ) に接続するリンクをCreateするために使う[アクティベーション トークン](https://developer.1password.com/docs/partnership-api/reference/#activation-tokens)。<https://start.\\[1password\\_domain]/partnership/redeem?t=\\[account\\_type]\\&c=\\[activation\\_token]\\&l=\\[language\\_code]トークンは> 1Password の個人アカウントまたはファミリー アカウントでのみ使用できます。チーム アカウントとビジネス アカウントはサポートされていません。 |
| **domain**                 | string  | 顧客がパートナーの課金サービスで使用できる新規または保存済みの 1Password アカウントのドメイン。テスト サーバーの場合: b5test.com、b5test.ca、またはb5test.eu。実稼働サーバーの場合: 1password.com、1password.ca、または1password.eu。                                                                                                                                                                                                                                     |
| **status**                 | string  | <p>顧客の請求アカウントのステータス。可能な値は次のいずれかです。</p><ul><li>entitledプロビジョニングは開始されましたが、顧客は新規または保存済みの 1Password アカウントでパートナーの請求リンクを使用していません。</li><li>provisioned顧客は新規または保存済みの 1Password アカウントでパートナーの請求リンクを使用し、サードパーティの請求アカウントがプロビジョニングされています。</li></ul>                                                                                                                                                          |
| **deployed\_members**      | integer | 1Password アカウントにプロビジョニングされたユーザーの数。                                                                                                                                                                                                                                                                                                                                                              |
| **created\_at**            | string  | 顧客の請求アカウントがCreateされた日時。ISO [8601 標準](https://www.iso.org/iso-8601-date-and-time-format.html)を使用します。                                                                                                                                                                                                                                                                                             |
| **updated\_at**            | string  | 顧客の請求先アカウントが最後に更新された日時。ISO [8601 標準](https://www.iso.org/iso-8601-date-and-time-format.html)を使用します。このフィールドは、アカウントのステータスが変更されると更新されます。                                                                                                                                                                                                                                                           |
| **ends\_at**               | string  | 顧客の請求アカウントがパートナーの請求サービスから削除される予定の日時。ISO [8601 標準](https://www.iso.org/iso-8601-date-and-time-format.html)を使用します。日時が指定されていない場合、期待値は nullです。                                                                                                                                                                                                                                                      |

#### **エラー応答** <a href="#miujdlvm5qz" id="miujdlvm5qz"></a>

403認証ヘッダーが欠落しているか、無効なトークンが指定された場合に返されます。

**Example error**

{

"code": 403,

"error": "forbidden",

"description": "Invalid auth token."

}

**Error object schema**

| **パラメータ**       | **タイプ**     | **説明**                  |
| --------------- | ----------- | ----------------------- |
| **code**        | **integer** | **エラーの HTTP 応答コード。**    |
| **error**       | **string**  | **コードを表す、機械で解析可能な文字列。** |
| **description** | **string**  | **エラーの説明。**             |

404リソースまたはリソースの依［Save］関係が見つからない場合に返されます。

**Example error**

{

"code": 404,

"error": "not\_found",

"description": "Failed to find the requested account."

}

**Error object schema**

| **パラメータ**       | **タイプ**     | **説明**                  |
| --------------- | ----------- | ----------------------- |
| **code**        | **integer** | **エラーの HTTP 応答コード。**    |
| **error**       | **string**  | **コードを表す、機械で解析可能な文字列。** |
| **description** | **string**  | **エラーの説明。**             |

410リソースが削除されたときに返されます。

**Example error**

{

"code": 410,

"error": "gone",

"description": "The requested account is gone."

}

**Error object schema**

| **パラメータ**       | **タイプ**     | **説明**                  |
| --------------- | ----------- | ----------------------- |
| **code**        | **integer** | **エラーの HTTP 応答コード。**    |
| **error**       | **string**  | **コードを表す、機械で解析可能な文字列。** |
| **description** | **string**  | **エラーの説明。**             |

500予期しないエラーが発生した場合に返されます。

**Example error**

{

"code": 500,

"error": "internal\_server\_error",

"description": "Internal server error"

}

**Error object schema**

| **パラメータ**       | **タイプ**     | **説明**                  |
| --------------- | ----------- | ----------------------- |
| **code**        | **integer** | **エラーの HTTP 応答コード。**    |
| **error**       | **string**  | **コードを表す、機械で解析可能な文字列。** |
| **description** | **string**  | **エラーの説明。**             |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://manual.dxable.com/1password/partnership-api-reference.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
