本文へスキップ

アーティファクトとカタログ ​

公開済みのアーティファクト:一覧、詳細、コンテンツ、注釈、参照、検索、カタログの監査とその変更フィード。

このグループの操作と、それぞれのアクセスルール、再試行ルール、パラメーター、レスポンスです。すべてのリクエストにはキーを付けます:Authorization: Bearer <key>(「認証」を参照)。

操作 ​

アーティファクトのアノテーションの取得 ​

GET HEAD /api/v1/repositories/{repository}/artifacts/{id}/annotations

アクセス: リポジトリ権限:annotation.read; ファイルキー:read · 再試行: 再試行しても安全(読み取り)

公開済みアーティファクトの現在のラベル、メタデータ、コレクションを、そのrevisionとともに返します。リビジョン0は、一度も置換されていないことを意味します。ラベルとメタデータはアップロードの作成時に指定されたもので、コレクションは空です。このリビジョンをsetAnnotationsのexpectedRevisionとして渡してください。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
idパスstring (uuid)はい—

レスポンス 200

フィールド型必須ルール
revisionintegerはい0~2147483647
labelsstringの配列はい32個以内の要素
metadatastringのマップはい32個以内のエントリ
collectionsstringの配列はい32個以内の要素

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts/$ID/annotations" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

アーティファクトのアノテーションの置換 ​

PUT /api/v1/repositories/{repository}/artifacts/{id}/annotations

アクセス: リポジトリ権限:annotation.write, artifact.read; ファイルキー:read, write · 再試行: 想定するリビジョンを指定した場合のみ再試行(compare-and-swap)

公開済みアーティファクトのlabels、metadata、collectionsを一括で置換します。valueに含めなかったフィールドは空になります。expectedRevisionは現在のリビジョン(最初の変更では0)でなければならず、そうでない場合は409 revision_mismatchになります。その場合はアノテーションを読み取り直して、変更をもう一度適用してください。ラベルとコレクションはそれぞれ最大32個(英字、数字、_.:-からなる1〜64文字)、メタデータは最大32エントリ(値は1024文字まで)です。バイト列と元のディスクリプターは変わりません。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
idパスstring (uuid)はい—

リクエスト本文 (application/json)

フィールド型必須ルール
expectedRevisionintegerはい0~2147483646
valueobjectはい—
value.labelsstringの配列いいえ32個以内の要素
value.metadatastringのマップいいえ32個以内のエントリ
value.collectionsstringの配列いいえ32個以内の要素

レスポンス 200

フィールド型必須ルール
revisionintegerはい0~2147483647
labelsstringの配列はい32個以内の要素
metadatastringのマップはい32個以内のエントリ
collectionsstringの配列はい32個以内の要素

レスポンス: 200, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X PUT "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts/$ID/annotations" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"expectedRevision":0,"value":{}}'

アーティファクトのUPackパッケージとしての登録 ​

POST /api/v1/repositories/{repository}/artifacts/{id}/package

アクセス: リポジトリ権限:package.publish, artifact.read; ファイルキー:read, write · 再試行: 再試行しても安全:同じリクエストは同じ効果になる

公開済みアーティファクトをUPack ZIPとして開き、ルートのupack.json(name、任意のgroup、SemVerのversion)を読み取って、そのパッケージバージョンを登録します。安全でないアーカイブや不正なアーカイブは400で拒否されます。バージョンは不変です。同じアーティファクトを再度登録すると同じエントリが返り、既存のグループ、名前、バージョンの組(大文字小文字を区別せずに比較)に別のアーティファクトを登録しようとすると409 version_existsになります。登録後、そのバージョンはlistPackagesに表示され、名前、範囲、ステージで解決できるようになります。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
idパスstring (uuid)はい—

レスポンス 200

フィールド型必須ルール
groupstringいいえ—
namestringいいえ—
versionstringいいえ—
artifactIdstring (uuid)いいえ—
manifestobjectいいえ—

レスポンス: 200, 400, 401, 403, 404, 405, 409, 422, 503, 507

例

bash
curl -X POST "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts/$ID/package" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

アーティファクトの検索 ​

GET HEAD /api/v1/repositories/{repository}/search

アクセス: リポジトリ権限:artifact.list; ファイルキー:read · 再試行: 再試行しても安全(読み取り)

公開済みアーティファクトを、q(名前または現在のメタデータ値に含まれる、大文字小文字を区別しない部分文字列)、現在のラベルとの完全一致label、collection、および必ず組で指定するmetadataKeyとmetadataValueの完全一致で検索します。指定したフィルターはすべて一致する必要があります。結果はID順に100件ずつのページで返り、各項目にはサイズ、作成時刻と公開時刻、現在のラベル、プロモーションステージが含まれます。続きはafterにnextを設定して取得します。メタデータとコレクションは返されないため、getAnnotationsで読み取ってください。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
qクエリstringいいえ—
labelクエリstringいいえ—
collectionクエリstringいいえ—
afterクエリstringいいえ—
metadataKeyクエリstringいいえ^[a-zA-Z][a-zA-Z0-9_.-]{0,63}$に一致; 64文字以内; Exact metadata key; requires metadataValue.
metadataValueクエリstringいいえ1024文字以内; Exact case-sensitive value; requires metadataKey. Empty string is allowed.

レスポンス 200

フィールド型必須ルール
itemsobjectの配列はい100個以内の要素
items[].idstring (uuid)はい—
items[].namestringはい—
items[].sizestringはい10進数字で表した整数(文字列として送信); バイトサイズ(10進数の文字列)
items[].createdAtstring (date-time)はいアップロードの予約時刻
items[].publishedAtstring (date-time)はいnullも可; 公開時刻。記録がない場合にのみnull
items[].labelsstringの配列はい32個以内の要素; 現在のラベル。置換されている場合はアノテーション、そうでなければアップロード時のディスクリプター
items[].stagesstringの配列はい16個以内の要素; 各要素:^[a-z0-9][a-z0-9_.-]{0,31}$に一致; 現在のプロモーションステージ(バイト順)
nextstring (uuid)はいnullも可; 満杯のページの最後のID。afterとして渡します

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/search" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

リポジトリのカタログ監査の取得 ​

GET HEAD /api/v1/repositories/{repository}/audit

アクセス: リポジトリ権限:audit.read; ファイルキー:write · 再試行: 再試行しても安全(読み取り)

シーケンス番号after(既定は0)より後のリポジトリのカタログ変更を、古いものから最大100件返します。対象は、公開、削除、アノテーションと添付ファイルの変更、パッケージの登録、ファイルパスの変更、参照、ステージ、プロモーションで、それぞれに実行者、アクション、アーティファクト、時刻が含まれます。続きを読むには、ページの最後のsequenceをafterとして渡します。nextフィールドはありません。ダウンロードとサインインは含まれません。ミラーは、実行者を含まないlistCatalogChangesで変更に追従します。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
afterクエリstringいいえ—

レスポンス 200

フィールド型必須ルール
itemsobjectの配列いいえ—
items[].sequencestringいいえ—
items[].actorstringいいえ—
items[].actionstringいいえ—
items[].artifactIdstringいいえ—
items[].occurredAtstring (date-time)いいえ—

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/audit" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

アーティファクトへの参照の追加 ​

POST /api/v1/repositories/{repository}/artifacts/{id}/references

アクセス: リポジトリ権限:reference.write, artifact.read; ファイルキー:read, write · 再試行: 再試行しても安全:同じリクエストは同じ効果になる

Arkvoryの外部の何かがこのアーティファクトを使用していることを、任意のkey(英字、数字、_.:/-からなる1〜256文字。たとえばデプロイ名)で記録します。参照があるアーティファクトは、すべての参照がなくなるまで、削除も保持ルールによる削除もできません。参照は呼び出し元に属し、同じキーを再度追加しても何も変わりません。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
idパスstring (uuid)はい—

リクエスト本文 (application/json)

フィールド型必須ルール
keystringはい256文字以内

レスポンス: 204, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X POST "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts/$ID/references" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"key":"<key>"}'

アーティファクトからの参照の削除 ​

DELETE /api/v1/repositories/{repository}/artifacts/{id}/references

アクセス: リポジトリ権限:reference.write, artifact.read; ファイルキー:read, write · 再試行: 再試行しても安全:同じリクエストは同じ効果になる

アーティファクトから呼び出し元自身の参照keyを削除します。他の呼び出し元の参照は残ります。存在しないキーを削除した場合も成功します。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
idパスstring (uuid)はい—

リクエスト本文 (application/json)

フィールド型必須ルール
keystringはい256文字以内

レスポンス: 204, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X DELETE "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts/$ID/references" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"key":"<key>"}'

アーティファクトの一覧表示 ​

GET HEAD /api/v1/repositories/{repository}/artifacts

アクセス: リポジトリ権限:artifact.list; ファイルキー:read · 再試行: 再試行しても安全(読み取り)

リポジトリの公開済みアーティファクトをID順に、1ページあたりlimit件(1〜100、既定は50)で列挙します。続きはafterにnextを設定して取得します。ページが満杯のときは常にnextが設定されるため、最後のページが空になることがあります。各項目にはアップロード時に指定されたディスクリプターが含まれます。現在のラベルとメタデータはgetAnnotationsで取得できます。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
afterクエリstring (uuid)いいえ—
limitクエリintegerいいえ1~100; 既定値:50

レスポンス 200

フィールド型必須ルール
itemsobjectの配列いいえ—
items[].idstring (uuid)はい—
items[].repositorystringはい—
items[].statusstringはい次のいずれか:pending, available, cancelled
items[].createdAtstring (date-time)はい—
items[].expiresAtstring (date-time)はい—
items[].descriptorobjectはい—
items[].descriptor.namestringはい1~240文字
items[].descriptor.sizestringはい10進数字で表した整数(文字列として送信)
items[].descriptor.sha256stringはいSHA-256:小文字の16進数字64桁
items[].descriptor.labelsstringの配列いいえ32個以内の要素; 各要素:64文字以内
items[].descriptor.metadatastringのマップいいえ32個以内のエントリ
nextstringいいえnullも可

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

アーティファクトの取得 ​

GET HEAD /api/v1/repositories/{repository}/artifacts/{id}

アクセス: リポジトリ権限:artifact.read; ファイルキー:read · 再試行: 再試行しても安全(読み取り)

公開済みアーティファクトを返します。ID、リポジトリ、ステータス、作成時刻、アップロード時に指定されたディスクリプター(名前、サイズ、SHA-256、元のラベルとメタデータ)が含まれます。保留中、キャンセル済み、削除済みのアーティファクトは404で応答します。バイト列を読み取るにはdownloadArtifactを使用してください。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
idパスstring (uuid)はい—

レスポンス 200

フィールド型必須ルール
idstring (uuid)はい—
repositorystringはい—
statusstringはい次のいずれか:pending, available, cancelled
createdAtstring (date-time)はい—
expiresAtstring (date-time)はい—
descriptorobjectはい—
descriptor.namestringはい1~240文字
descriptor.sizestringはい10進数字で表した整数(文字列として送信)
descriptor.sha256stringはいSHA-256:小文字の16進数字64桁
descriptor.labelsstringの配列いいえ32個以内の要素; 各要素:64文字以内
descriptor.metadatastringのマップいいえ32個以内のエントリ

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts/$ID" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

アーティファクトの削除 ​

DELETE /api/v1/repositories/{repository}/artifacts/{id}

アクセス: リポジトリ権限:artifact.delete · 再試行: 再試行しても安全:同じリクエストは同じ効果になる

公開済みアーティファクトを論理削除します。一覧、検索、ダウンロードからはただちに消え、そのバイト列はリポジトリの物理クリーンアップ(setCleanup、既定ではオフ)によって猶予期間の経過後に回収されます。expectedAnnotationRevisionは現在のアノテーションのリビジョンと等しくなければなりません。応答は200で、outcomeはdeleted、already_deleted、changed(リビジョンが異なる)、not_found、または削除を妨げているもの(参照、ファイルパスのリビジョン、ビルドの添付ファイル、プロモーションステージ)を示すblockersを伴うprotectedのいずれかです。事前にinspectArtifactDeletionで確認してください。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
idパスstring (uuid)はい—

リクエスト本文 (application/json)

フィールド型必須ルール
expectedAnnotationRevisionintegerはい0~2147483647

レスポンス 200

フィールド型必須ルール
idstring (uuid)はい—
outcomestringはい次のいずれか:deleted, already_deleted, protected, changed, not_eligible, not_found
blockersstringの配列はい4個以内の要素; 要素の重複なし; 各要素:次のいずれか:reference, asset_history, attachment_history, protected_label, promotion_stage

レスポンス: 200, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X DELETE "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts/$ID" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"expectedAnnotationRevision":0}'

アーティファクトのダウンロード ​

GET HEAD /api/v1/repositories/{repository}/artifacts/{id}/content

アクセス: リポジトリ権限:content.read; ファイルキー:read · 再試行: 再試行しても安全(読み取り)

元のバイト列を、Content-Length、Content-Disposition(アーティファクト名)、強いETag("sha256:<hex>")とともにストリームで返します。単一のRangeには206で応答し(満たせない場合は416)、ETagを指定したIf-Rangeで安全に再開でき、If-None-Matchには304で応答します。HEADは本文なしで同じヘッダーを返し、Rangeは無視します。Authorizationヘッダーの代わりに、createDownloadLinkで作成したダウンロードリンクをtokenとして付けることもできます。ダウンロードは、サーバーのダウンロード受け入れ枠に空きが出るまで待機します。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
idパスstring (uuid)はい—
Rangeヘッダーstringいいえ—
If-Rangeヘッダーstringいいえ—
If-None-Matchヘッダーstringいいえ—
Arkvory-Download-Idヘッダーstringいいえ^[A-Za-z0-9_-]{16,64}$に一致; The client own id of one download, the same on every range of it: the queue keys the session by it instead of the client address, answers a waiting request at once with 503 download_queued, and may ask it to yield its place at a range boundary. Without it, a waiting request is held until its turn for a bounded time.
Arkvory-Queue-Ticketヘッダーstringいいえ80文字以内; The last Arkvory-Queue-Ticket the server sent for this download: after a server restart the download takes its old turn. A ticket that is wrong, expired or of another download is ignored.
Arkvory-Download-Classヘッダーstringいいえ次のいずれか:interactive, release, bulk, background; Queue class of the download. Only a class lower than the caller own one applies (people: interactive, services and links: release); an unknown value is 400. The response names the class applied.
tokenクエリstringいいえ^dtl_[A-Za-z0-9_-]{43}$に一致; Download link from POST …/artifacts/{id}/links, instead of an Authorization header

レスポンス: 200, 206, 304, 400, 401, 403, 404, 409, 416, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts/$ID/content" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -o file

サイトの概要を読む ​

GET HEAD /api/v1/fleet/overview

アクセス: 管理者 · 再試行: 再試行しても安全(読み取り)

管理対象サイトとこのインストールのアラート(重大なものから critical、warning、info)と、それらの間のミラーのリンク。直近のバックグラウンド読み取りから最大 5 秒に 1 回作成されます。どの管理対象サイトもそのアドレスで応答しないソースは external:<origin>、このインストールは self で、ARKVORY_SITE_URL を設定したときだけこのインストールへのリンクが現れます。書き込みプロセスのみが応答します。

レスポンス 200

フィールド型必須ルール
generatedAtstring (date-time)はい—
selfobjectはい—
self.namestringはい—
self.versionstringはい—
self.urlstringはいnullも可
alertsobjectの配列はい—
alerts[].sitestringはい—
alerts[].namestringはい—
alerts[].kindstringはい次のいずれか:unreachable, certificate, revoked, refused, invalid, stale, not-writable, copies, single-copy, mirror-failing, mirror-lag, updates-failed, version-skew
alerts[].severitystringはい次のいずれか:critical, warning, info
alerts[].subjectstringはいnullも可
alerts[].sincestring (date-time)はいnullも可
linksobjectの配列はい—
links[].fromstringはい—
links[].tostringはい—
links[].repositorystringはい—
links[].sourceRepositorystringはい—
links[].modestringはい次のいずれか:mirror, import
links[].lagChangesstringはい10進数字で表した整数(文字列として送信); nullも可
links[].failingbooleanはい—
links[].stalebooleanいいえ—
externalstringの配列はい—

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/fleet/overview" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

管理しているサイトの一覧 ​

GET HEAD /api/v1/fleet/sites

アクセス: 管理者 · 再試行: 再試行しても安全(読み取り)

このインストールが管理するサイト(ADR 0077)と、各サイトが最後に報告した内容:state(ok、または読めなかった理由:unreachable、certificate、revoked、invalid、refused)、最後に確認できた時刻、最後の topology。サイトはバックグラウンドで30秒ごとに読み取ります。サイトのキーは返しません。

レスポンス 200

フィールド型必須ルール
itemsobjectの配列はい256個以内の要素
items[].idstring (uuid)はい—
items[].namestringはい—
items[].urlstringはい—
items[].fingerprintstringはい^[0-9a-f]{64}$に一致; nullも可
items[].addedBystringはい—
items[].addedAtstring (date-time)はい—
items[].seenAtstring (date-time)はいnullも可
items[].statestringはい次のいずれか:pending, ok, unreachable, certificate, revoked, invalid, refused
items[].errorstringはいnullも可
items[].topologyobjectはいnullも可
items[].topology.collectedAtstring (date-time)はい—
items[].topology.siteobjectはい—
items[].topology.healthobjectはい—
items[].topology.replicationobjectはいnullも可
items[].topology.gatewaysobjectの配列はい16個以内の要素
items[].topology.mirrorsobjectの配列はい64個以内の要素
items[].topology.updatesobjectはいnullも可
items[].topology.downloadsobjectはい—

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/fleet/sites" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

サイトとペアリング ​

POST /api/v1/fleet/sites

アクセス: 管理者 · 再試行: 自動的に再試行しない

サイトとペアリングします:コントローラーが再接続し、証明書は管理者が確認した fingerprint のままでなければなりません(loopback の HTTP は null)。サイトで作成したペアリング code をキーと交換し、キーは ARKVORY_FLEET_KEY_FILE で封印します。応答の前にサイトを一度読み取ります。キーファイルがなければ応答は 503 です。

リクエスト本文 (application/json)

フィールド型必須ルール
urlstringはい—
fingerprintstringはい^[0-9a-f]{64}$に一致; nullも可
codestringはい32文字以内

レスポンス 201

フィールド型必須ルール
idstring (uuid)はい—
namestringはい—
urlstringはい—
fingerprintstringはい^[0-9a-f]{64}$に一致; nullも可
addedBystringはい—
addedAtstring (date-time)はい—
seenAtstring (date-time)はいnullも可
statestringはい次のいずれか:pending, ok, unreachable, certificate, revoked, invalid, refused
errorstringはいnullも可
topologyobjectはいnullも可
topology.collectedAtstring (date-time)はい—
topology.siteobjectはい—
topology.site.namestringはい—
topology.site.versionstringはい—
topology.site.schemaintegerはい0以上
topology.site.rolestringはい次のいずれか:api, reader
topology.healthobjectはい—
topology.health.availablebooleanはい—
topology.health.writablebooleanはい—
topology.health.drainingbooleanはい—
topology.replicationobjectはいnullも可
topology.replication.copiesintegerはい0~16
topology.replication.requiredintegerはい1~16
topology.replication.singleCopyUntilstring (date-time)はいnullも可
topology.replication.nodestringいいえ63文字以内
topology.replication.profilestringいいえ次のいずれか:ha-2, ha-3
topology.replication.peersobjectの配列いいえ16個以内の要素
topology.gatewaysobjectの配列はい16個以内の要素
topology.gateways[].slotintegerはい0以上
topology.gateways[].activebooleanはい—
topology.gateways[].expiresAtstring (date-time)はい—
topology.mirrorsobjectの配列はい64個以内の要素
topology.mirrors[].repositorystringはい—
topology.mirrors[].modestringはい次のいずれか:mirror, import
topology.mirrors[].upstreamstringはい—
topology.mirrors[].sourceRepositorystringはい—
topology.mirrors[].phasestringはい—
topology.mirrors[].errorCodestringはいnullも可
topology.mirrors[].checkedAtstring (date-time)はいnullも可
topology.mirrors[].syncedAtstring (date-time)はいnullも可
topology.mirrors[].lagChangesstringはい10進数字で表した整数(文字列として送信); nullも可
topology.mirrors[].copiedArtifactsintegerはい0以上
topology.mirrors[].copiedBytesstringはい10進数字で表した整数(文字列として送信)
topology.updatesobjectはいnullも可
topology.updates.currentVersionstringはい—
topology.updates.lateststringはいnullも可
topology.updates.phasestringはい—
topology.updates.errorstringはいnullも可
topology.updates.automaticbooleanはい—
topology.updates.heartbeatAtstring (date-time)はい—
topology.downloadsobjectはい—
topology.downloads.strategystringはい次のいずれか:ordered, smallest-first, shared
topology.downloads.sessionsintegerはい0以上
topology.downloads.activeintegerはい0以上
topology.downloads.waitingintegerはい0以上
topology.downloads.oldestWaitSecondsintegerはい0以上
topology.downloads.bytesPerSecondintegerはい0以上

レスポンス: 201, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X POST "$ARKVORY_URL/api/v1/fleet/sites" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"url":"<url>","fingerprint":"<fingerprint>","code":"<code>"}'

サイトの証明書を読む ​

POST /api/v1/fleet/sites/probe

アクセス: 管理者 · 再試行: 再試行しても安全:同じリクエストは同じ効果になる

アドレスに接続し、何も送らずにサイトの証明書を読みます:ペアリング前に fingerprint をサイトの管理者が見ているものと比べてください。

リクエスト本文 (application/json)

フィールド型必須ルール
urlstringはい—

レスポンス 200

フィールド型必須ルール
urlstringはい—
certificateobjectはいnullも可
certificate.fingerprintstringはい^[0-9a-f]{64}$に一致
certificate.subjectstringはい—
certificate.issuerstringはい—
certificate.validTostring (date-time)はい—

レスポンス: 200, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X POST "$ARKVORY_URL/api/v1/fleet/sites/probe" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"url":"<url>"}'

サイトを忘れる ​

DELETE /api/v1/fleet/sites/{id}

アクセス: 管理者 · 再試行: 再試行しても安全:同じリクエストは同じ効果になる

ここでサイトと封印されたキーを削除します。サイト側でもこのコントローラーを取り消してください。それまでキーはそこで有効です。

パラメーター

名前場所型必須ルール
idパスstring (uuid)はい—

レスポンス: 204, 400, 401, 403, 404, 405, 409, 422, 503, 507

例

bash
curl -X DELETE "$ARKVORY_URL/api/v1/fleet/sites/$ID" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

サイトのカタログを読む ​

GET HEAD /api/v1/fleet/sites/{id}/read

アクセス: 管理者 · 再試行: 再試行しても安全(読み取り)

カタログの読み取りを 1 回、管理対象サイトに渡し、その応答をそのまま返します:リポジトリ、検索、アーティファクト、注釈、ステージ、パッケージ、ファイルのページと履歴、ストレージ使用量、ミラーの状態。path はクエリ付きのサイトのルートです。その他のルートとファイルのバイトは 400 で拒否されます。

パラメーター

名前場所型必須ルール
idパスstring (uuid)はい—
pathクエリstringはい^/api/v1/に一致; 2048文字以内; A read route of the site with its query, from a fixed list: catalog metadata (repositories, search, artifacts, annotations, stages, packages, file pages and history, storage usage, mirror state), download queue settings and update state. Never file bytes.

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/fleet/sites/$ID/read?path=$PATH" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

サイトの設定を変更する ​

POST /api/v1/fleet/sites/{id}/change

アクセス: 管理者 · 再試行: 自動的に再試行しない

変更を 1 つ管理対象サイトに渡し、その応答をそのまま返します。path は次のいずれかのルートです:/api/v1/system/downloads/settings(ダウンロードキューの設定、PUT で送信)または /api/v1/system/updates/requests(更新リクエスト、POST で送信)。本文はそのままサイトに届きます。サイトがリビジョンまたはリクエスト id を確認するため、繰り返された変更が二重に適用されることはありません。その他のパスは 400 で拒否されます。

パラメーター

名前場所型必須ルール
idパスstring (uuid)はい—
pathクエリstringはい^/api/v1/に一致; 2048文字以内; A change route of the site, from a fixed list: PUT /api/v1/system/downloads/settings, POST /api/v1/system/updates/requests.

リクエスト本文 (application/json)

レスポンス: 200, 202, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X POST "$ARKVORY_URL/api/v1/fleet/sites/$ID/change?path=$PATH" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}'

今すぐサイトを読む ​

POST /api/v1/fleet/sites/{id}/refresh

アクセス: 管理者 · 再試行: 再試行しても安全:同じリクエストは同じ効果になる

次の巡回を待たずに今サイトを読み、新しい状態で返します。

パラメーター

名前場所型必須ルール
idパスstring (uuid)はい—

レスポンス 200

フィールド型必須ルール
idstring (uuid)はい—
namestringはい—
urlstringはい—
fingerprintstringはい^[0-9a-f]{64}$に一致; nullも可
addedBystringはい—
addedAtstring (date-time)はい—
seenAtstring (date-time)はいnullも可
statestringはい次のいずれか:pending, ok, unreachable, certificate, revoked, invalid, refused
errorstringはいnullも可
topologyobjectはいnullも可
topology.collectedAtstring (date-time)はい—
topology.siteobjectはい—
topology.site.namestringはい—
topology.site.versionstringはい—
topology.site.schemaintegerはい0以上
topology.site.rolestringはい次のいずれか:api, reader
topology.healthobjectはい—
topology.health.availablebooleanはい—
topology.health.writablebooleanはい—
topology.health.drainingbooleanはい—
topology.replicationobjectはいnullも可
topology.replication.copiesintegerはい0~16
topology.replication.requiredintegerはい1~16
topology.replication.singleCopyUntilstring (date-time)はいnullも可
topology.replication.nodestringいいえ63文字以内
topology.replication.profilestringいいえ次のいずれか:ha-2, ha-3
topology.replication.peersobjectの配列いいえ16個以内の要素
topology.gatewaysobjectの配列はい16個以内の要素
topology.gateways[].slotintegerはい0以上
topology.gateways[].activebooleanはい—
topology.gateways[].expiresAtstring (date-time)はい—
topology.mirrorsobjectの配列はい64個以内の要素
topology.mirrors[].repositorystringはい—
topology.mirrors[].modestringはい次のいずれか:mirror, import
topology.mirrors[].upstreamstringはい—
topology.mirrors[].sourceRepositorystringはい—
topology.mirrors[].phasestringはい—
topology.mirrors[].errorCodestringはいnullも可
topology.mirrors[].checkedAtstring (date-time)はいnullも可
topology.mirrors[].syncedAtstring (date-time)はいnullも可
topology.mirrors[].lagChangesstringはい10進数字で表した整数(文字列として送信); nullも可
topology.mirrors[].copiedArtifactsintegerはい0以上
topology.mirrors[].copiedBytesstringはい10進数字で表した整数(文字列として送信)
topology.updatesobjectはいnullも可
topology.updates.currentVersionstringはい—
topology.updates.lateststringはいnullも可
topology.updates.phasestringはい—
topology.updates.errorstringはいnullも可
topology.updates.automaticbooleanはい—
topology.updates.heartbeatAtstring (date-time)はい—
topology.downloadsobjectはい—
topology.downloads.strategystringはい次のいずれか:ordered, smallest-first, shared
topology.downloads.sessionsintegerはい0以上
topology.downloads.activeintegerはい0以上
topology.downloads.waitingintegerはい0以上
topology.downloads.oldestWaitSecondsintegerはい0以上
topology.downloads.bytesPerSecondintegerはい0以上

レスポンス: 200, 400, 401, 403, 404, 405, 409, 422, 503, 507

例

bash
curl -X POST "$ARKVORY_URL/api/v1/fleet/sites/$ID/refresh" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

ペアリングコードを作成 ​

POST /api/v1/system/fleet/pairings

アクセス: 管理者 · 再試行: 自動的に再試行しない

コントローラーの管理者がこのサイトを管理するために入力する、10分間有効な使い捨てコードを作成します。コードは一度だけ表示され、ハッシュとしてのみ保存されます。作成できるのはサイトのグローバル管理者だけです。

レスポンス 201

フィールド型必須ルール
codestringはい^[0-9A-Z]{4}-[0-9A-Z]{4}-[0-9A-Z]{4}$に一致
expiresAtstring (date-time)はい—
fingerprintstringはい^[0-9a-f]{64}$に一致; nullも可

レスポンス: 201, 400, 401, 403, 404, 405, 409, 422, 503, 507

例

bash
curl -X POST "$ARKVORY_URL/api/v1/system/fleet/pairings" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

このサイトのコントローラー一覧 ​

GET HEAD /api/v1/system/fleet/controllers

アクセス: 管理者 · 再試行: 再試行しても安全(読み取り)

このサイトを管理できるコントローラーを一覧表示します:名前、誰がいつペアリングしたか、キーが最後に使われた時刻。

レスポンス 200

フィールド型必須ルール
itemsobjectの配列はい100個以内の要素
items[].idstring (uuid)はい—
items[].namestringはい—
items[].pairedBystringはい—
items[].pairedAtstring (date-time)はい—
items[].usedAtstring (date-time)はいnullも可

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/system/fleet/controllers" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

コントローラーを取り消す ​

DELETE /api/v1/system/fleet/controllers/{id}

アクセス: 管理者 · 再試行: 再試行しても安全:同じリクエストは同じ効果になる

コントローラーを取り消します:そのフリートキーは直ちに拒否されます。再びサイトを管理するには新しいコードでペアリングが必要です。

パラメーター

名前場所型必須ルール
idパスstring (uuid)はい—

レスポンス: 204, 400, 401, 403, 404, 405, 409, 422, 503, 507

例

bash
curl -X DELETE "$ARKVORY_URL/api/v1/system/fleet/controllers/$ID" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

コントローラーとペアリング ​

POST /api/v1/system/fleet/enrollment

アクセス: 誰でも(キー不要) · 再試行: 自動的に再試行しない

有効なペアリングコードを一度だけフリートキーと交換します。コントローラーは管理者が確認したフィンガープリントに固定した TLS で呼び出します。キーは一度だけ返され、コントローラーに必要なルートにだけ届きます。

リクエスト本文 (application/json)

フィールド型必須ルール
codestringはい32文字以内
namestringはい1~63文字

レスポンス 201

フィールド型必須ルール
keystringはい^afk_[A-Za-z0-9_-]{43}$に一致
siteobjectはい—
site.namestringはい—
site.versionstringはい—

レスポンス: 201, 400, 403, 405, 413, 415, 503

例

bash
curl -X POST "$ARKVORY_URL/api/v1/system/fleet/enrollment" \
  -H "Content-Type: application/json" \
  -d '{"code":"<code>","name":"<name>"}'

フリートコンソール用にこのサイトを取得 ​

GET HEAD /api/v1/system/topology

アクセス: 管理者 · 再試行: 再試行しても安全(読み取り)

このインストールをフリートの1サイトとして返します(ADR 0077):名前、バージョン、スキーマと役割、利用可能か・書き込み可能か、HA のコピーとノード、リースに基づく読み取りゲートウェイ、各ミラーとインポートのフェーズ・最終同期・lagChanges(まだ適用されていない元の変更)、更新エージェントの状態とダウンロードキュー。サイトのグローバル管理者かペアリング済みのコントローラーだけが読めます。

レスポンス 200

フィールド型必須ルール
collectedAtstring (date-time)はい—
siteobjectはい—
site.namestringはい—
site.versionstringはい—
site.schemaintegerはい0以上
site.rolestringはい次のいずれか:api, reader
healthobjectはい—
health.availablebooleanはい—
health.writablebooleanはい—
health.drainingbooleanはい—
replicationobjectはいnullも可
replication.copiesintegerはい0~16
replication.requiredintegerはい1~16
replication.singleCopyUntilstring (date-time)はいnullも可
replication.nodestringいいえ63文字以内
replication.profilestringいいえ次のいずれか:ha-2, ha-3
replication.peersobjectの配列いいえ16個以内の要素
replication.peers[].namestringはい63文字以内
replication.peers[].connectedbooleanはい—
replication.peers[].diskstringはい24文字以内
replication.peers[].completebooleanはい—
replication.peers[].witnessbooleanはい—
gatewaysobjectの配列はい16個以内の要素
gateways[].slotintegerはい0以上
gateways[].activebooleanはい—
gateways[].expiresAtstring (date-time)はい—
mirrorsobjectの配列はい64個以内の要素
mirrors[].repositorystringはい—
mirrors[].modestringはい次のいずれか:mirror, import
mirrors[].upstreamstringはい—
mirrors[].sourceRepositorystringはい—
mirrors[].phasestringはい—
mirrors[].errorCodestringはいnullも可
mirrors[].checkedAtstring (date-time)はいnullも可
mirrors[].syncedAtstring (date-time)はいnullも可
mirrors[].lagChangesstringはい10進数字で表した整数(文字列として送信); nullも可
mirrors[].copiedArtifactsintegerはい0以上
mirrors[].copiedBytesstringはい10進数字で表した整数(文字列として送信)
updatesobjectはいnullも可
updates.currentVersionstringはい—
updates.lateststringはいnullも可
updates.phasestringはい—
updates.errorstringはいnullも可
updates.automaticbooleanはい—
updates.heartbeatAtstring (date-time)はい—
downloadsobjectはい—
downloads.strategystringはい次のいずれか:ordered, smallest-first, shared
downloads.sessionsintegerはい0以上
downloads.activeintegerはい0以上
downloads.waitingintegerはい0以上
downloads.oldestWaitSecondsintegerはい0以上
downloads.bytesPerSecondintegerはい0以上

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/system/topology" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

ダウンロードキューの設定を読む ​

GET HEAD /api/v1/system/downloads/settings

アクセス: 管理者 · 再試行: 再試行しても安全(読み取り)

変更された値(overrides)、サーバーの環境が定める値(defaults)、キューが現在使っている値(effective)と、変更時に返すリビジョンを返します。problem は保存された設定がこのサーバーに合わない理由を示します。その場合キューは既定値で動作します。

レスポンス 200

フィールド型必須ルール
revisionintegerはい0~9007199254740991
overridesobjectはい—
overrides.strategystringいいえ次のいずれか:ordered, smallest-first, shared
overrides.sessionsintegerいいえ1~1024
overrides.reserveintegerいいえ0~1023
overrides.perPrincipalintegerいいえ1~1024
overrides.weightsobjectいいえ—
overrides.weights.interactiveintegerはい1~1000
overrides.weights.releaseintegerはい1~1000
overrides.weights.bulkintegerはい1~1000
overrides.weights.backgroundintegerはい1~1000
overrides.sessionMinBytesintegerいいえ0~9007199254740991
overrides.idleSecondsintegerいいえ1~3600
overrides.agingMinutesintegerいいえ0~10080
overrides.preemptbooleanいいえ—
overrides.rangesPerSessionintegerいいえ1~64
defaultsobjectはい—
defaults.strategystringはい次のいずれか:ordered, smallest-first, shared
defaults.sessionsintegerはい1~1024
defaults.reserveintegerはい0~1023
defaults.perPrincipalintegerはい1~1024
defaults.weightsobjectはい—
defaults.weights.interactiveintegerはい1~1000
defaults.weights.releaseintegerはい1~1000
defaults.weights.bulkintegerはい1~1000
defaults.weights.backgroundintegerはい1~1000
defaults.sessionMinBytesintegerはい0~9007199254740991
defaults.idleSecondsintegerはい1~3600
defaults.agingMinutesintegerはい0~10080
defaults.preemptbooleanはい—
defaults.rangesPerSessionintegerはい1~64
effectiveobjectはい—
effective.strategystringはい次のいずれか:ordered, smallest-first, shared
effective.sessionsintegerはい1~1024
effective.reserveintegerはい0~1023
effective.perPrincipalintegerはい1~1024
effective.weightsobjectはい—
effective.weights.interactiveintegerはい1~1000
effective.weights.releaseintegerはい1~1000
effective.weights.bulkintegerはい1~1000
effective.weights.backgroundintegerはい1~1000
effective.sessionMinBytesintegerはい0~9007199254740991
effective.idleSecondsintegerはい1~3600
effective.agingMinutesintegerはい0~10080
effective.preemptbooleanはい—
effective.rangesPerSessionintegerはい1~64
admissionstringはい次のいずれか:sessions, per-request
updatedAtstring (date-time)はいnullも可
updatedBystringはいnullも可
actorstringはいnullも可
problemstringはいnullも可

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/system/downloads/settings" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

ダウンロードキューの設定を変更する ​

PUT /api/v1/system/downloads/settings

アクセス: 管理者 · 再試行: 想定するリビジョンを指定した場合のみ再試行(compare-and-swap)

overrides をサーバーの環境の上に保存し、再起動なしで適用します。新しい判断はすぐにそれに従い、進行中のダウンロードは場所を保ちます。渡した値はそれまでの変更をすべて置き換え、{} で環境の値に戻ります。このサーバーで動作できない設定はフィールド名付きの 400 で拒否され、古い expectedRevision は 409 になります。読み取りゲートウェイは自身の環境を保ちます。

リクエスト本文 (application/json)

フィールド型必須ルール
expectedRevisionintegerはい0~9007199254740991
overridesobjectはい—
overrides.strategystringいいえ次のいずれか:ordered, smallest-first, shared
overrides.sessionsintegerいいえ1~1024
overrides.reserveintegerいいえ0~1023
overrides.perPrincipalintegerいいえ1~1024
overrides.weightsobjectいいえ—
overrides.weights.interactiveintegerはい1~1000
overrides.weights.releaseintegerはい1~1000
overrides.weights.bulkintegerはい1~1000
overrides.weights.backgroundintegerはい1~1000
overrides.sessionMinBytesintegerいいえ0~9007199254740991
overrides.idleSecondsintegerいいえ1~3600
overrides.agingMinutesintegerいいえ0~10080
overrides.preemptbooleanいいえ—
overrides.rangesPerSessionintegerいいえ1~64

レスポンス 200

フィールド型必須ルール
revisionintegerはい0~9007199254740991
overridesobjectはい—
overrides.strategystringいいえ次のいずれか:ordered, smallest-first, shared
overrides.sessionsintegerいいえ1~1024
overrides.reserveintegerいいえ0~1023
overrides.perPrincipalintegerいいえ1~1024
overrides.weightsobjectいいえ—
overrides.weights.interactiveintegerはい1~1000
overrides.weights.releaseintegerはい1~1000
overrides.weights.bulkintegerはい1~1000
overrides.weights.backgroundintegerはい1~1000
overrides.sessionMinBytesintegerいいえ0~9007199254740991
overrides.idleSecondsintegerいいえ1~3600
overrides.agingMinutesintegerいいえ0~10080
overrides.preemptbooleanいいえ—
overrides.rangesPerSessionintegerいいえ1~64
defaultsobjectはい—
defaults.strategystringはい次のいずれか:ordered, smallest-first, shared
defaults.sessionsintegerはい1~1024
defaults.reserveintegerはい0~1023
defaults.perPrincipalintegerはい1~1024
defaults.weightsobjectはい—
defaults.weights.interactiveintegerはい1~1000
defaults.weights.releaseintegerはい1~1000
defaults.weights.bulkintegerはい1~1000
defaults.weights.backgroundintegerはい1~1000
defaults.sessionMinBytesintegerはい0~9007199254740991
defaults.idleSecondsintegerはい1~3600
defaults.agingMinutesintegerはい0~10080
defaults.preemptbooleanはい—
defaults.rangesPerSessionintegerはい1~64
effectiveobjectはい—
effective.strategystringはい次のいずれか:ordered, smallest-first, shared
effective.sessionsintegerはい1~1024
effective.reserveintegerはい0~1023
effective.perPrincipalintegerはい1~1024
effective.weightsobjectはい—
effective.weights.interactiveintegerはい1~1000
effective.weights.releaseintegerはい1~1000
effective.weights.bulkintegerはい1~1000
effective.weights.backgroundintegerはい1~1000
effective.sessionMinBytesintegerはい0~9007199254740991
effective.idleSecondsintegerはい1~3600
effective.agingMinutesintegerはい0~10080
effective.preemptbooleanはい—
effective.rangesPerSessionintegerはい1~64
admissionstringはい次のいずれか:sessions, per-request
updatedAtstring (date-time)はいnullも可
updatedBystringはいnullも可
actorstringはいnullも可
problemstringはいnullも可

レスポンス: 200, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X PUT "$ARKVORY_URL/api/v1/system/downloads/settings" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"expectedRevision":0,"overrides":{}}'

サイトの変更を読む ​

GET HEAD /api/v1/system/changes

アクセス: 管理者 · 再試行: 再試行しても安全(読み取り)

サイトのエージェントが報告しているか(agent)、待機中のリクエスト、最新 20 件とその状態(pending、applying、done、または理由付きの failed)を返します。ソースキーがここに現れることはありません。

レスポンス 200

フィールド型必須ルール
agentbooleanはい—
updatingbooleanはい—
blockedstringはい次のいずれか:expired, interrupted, key_missing, not_a_mirror, already_attached, mirror_failed, switchover_failed, single_copy_failed, unreadable, digest_mismatch, null; nullも可
pendingobjectはいnullも可
pending.idstring (uuid)はい—
pending.kindstringはい次のいずれか:mirror-attach, mirror-key, mirror-detach, cluster-switchover, single-copy
pending.actorstringはい200文字以内
pending.requestedAtstring (date-time)はい—
recentobjectの配列はい20個以内の要素
recent[].idstring (uuid)はい—
recent[].digeststringはい^[0-9a-f]{64}$に一致
recent[].kindstringはい次のいずれか:mirror-attach, mirror-key, mirror-detach, cluster-switchover, single-copy
recent[].statestringはい次のいずれか:pending, applying, done, failed
recent[].errorstringはい次のいずれか:expired, interrupted, key_missing, not_a_mirror, already_attached, mirror_failed, switchover_failed, single_copy_failed, unreadable, digest_mismatch, null; nullも可
recent[].actorstringはい200文字以内
recent[].requestedAtstring (date-time)はい—
recent[].finishedAtstring (date-time)はいnullも可

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/system/changes" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

サイトの変更をキューに入れる ​

POST /api/v1/system/changes

アクセス: 管理者 · 再試行: 再試行しても安全:同じリクエストは同じ効果になる

サイトのエージェント向けに変更を 1 つキューに入れます。エージェントは 1 分以内に arkvory configure と cluster-* の検査とロールバック付きで適用します:ミラーまたはインポートの接続、ソースキーの交換、ミラーの切り離し、アクティブな HA ノードの切り替え(ノード名を 2 回入力)、単一コピー書き込みの決定。id はクライアントが選び、繰り返しても再度キューに入りません。key は mirror-attach と mirror-key のソースキーのみで、専用の 0600 ファイルでエージェントに渡り、返されることはありません。202 はキュー投入済みであり、適用済みではありません。

リクエスト本文 (application/json)

フィールド型必須ルール
idstring (uuid)はい—
changeobjectはい—
change.kindstringはい次のいずれか:mirror-attach
change.repositorystringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
change.upstreamstringはい255文字以内
change.sourceRepositorystringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
change.stagesstringの配列いいえ1~16個の要素; 各要素:^[a-z0-9][a-z0-9_.-]{0,31}$に一致; nullも可
change.repositoriesstringの配列はい1~64個の要素; 各要素:^[a-z0-9][a-z0-9_-]{0,63}$に一致
change.nodestringはい^[A-Za-z0-9][A-Za-z0-9_.-]{0,62}$に一致
change.confirmstringはい^[A-Za-z0-9][A-Za-z0-9_.-]{0,62}$に一致
change.untilstring (date-time)はいnullも可
change.reasonstringはい1~200文字
keystringいいえ16~4000文字

レスポンス 202

フィールド型必須ルール
idstring (uuid)はい—

レスポンス: 202, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X POST "$ARKVORY_URL/api/v1/system/changes" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"id":"00000000-0000-4000-8000-000000000000","change":{"kind":"mirror-attach","repository":"<repository>","upstream":"<upstream>","sourceRepository":"<sourceRepository>"}}'

リポジトリの変更フィードの取得 ​

GET HEAD /api/v1/repositories/{repository}/changes

アクセス: リポジトリ権限:artifact.list; ファイルキー:read · 再試行: 再試行しても安全(読み取り)

シーケンスafter(既定は0)より後の変更を、コミット順に最大limit件(1〜100、既定は100)返します。各変更には、アクションとアーティファクトが含まれ、ファイルパスとステージについては、そのパスまたはステージがdetailに含まれます。実行者は含まれないため、一覧表示の権限があれば十分です。headはリポジトリの最新のシーケンス、nextは次のページのカーソルで、ページがheadに達した場合はnullです。ミラーは最後に適用したシーケンスを保存し、そこからポーリングします。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
afterクエリstringいいえ10進数字で表した整数(文字列として送信); Sequence cursor, default 0
limitクエリintegerいいえ1~100

レスポンス 200

フィールド型必須ルール
itemsobjectの配列はい—
items[].sequencestringはい10進数字で表した整数(文字列として送信)
items[].actionstringはい—
items[].artifactIdstring (uuid)はい—
items[].detailstringはいnullも可
headstringはい10進数字で表した整数(文字列として送信)
nextstringはい10進数字で表した整数(文字列として送信); nullも可

レスポンス: 200, 400, 401, 403, 404, 409, 422, 503, 507

例

bash
curl -X GET "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/changes" \
  -H "Authorization: Bearer $ARKVORY_TOKEN"

POST /api/v1/repositories/{repository}/artifacts/{id}/links

アクセス: リポジトリ権限:content.read; ファイルキー:read · 再試行: 自動的に再試行しない

キーなしでこの1つのアーティファクトをdownloadArtifactするための、秘密のtoken、APIオリジンからの相対url、expiresAtを返します。ttlSecondsで有効期間を設定します(60秒〜1日、既定は1時間)。トークンはこの応答でのみ表示され、取り消せません。有効期限が切れるかアーティファクトが削除されると使えなくなり、これを通じたダウンロードは作成者の転送制限に計上されます。呼び出し元が保持できる有効なリンクは1000件までで(507 token_limit)、ダウンロードリンクから別のリンクを作成することはできません。

パラメーター

名前場所型必須ルール
repositoryパスstringはい^[a-z0-9][a-z0-9_-]{0,63}$に一致
idパスstring (uuid)はい—

リクエスト本文 (application/json)

フィールド型必須ルール
ttlSecondsintegerいいえ60~86400; 既定値:3600

レスポンス 201

フィールド型必須ルール
tokenstringはい^dtl_[A-Za-z0-9_-]{43}$に一致
urlstringはい—
expiresAtstring (date-time)はい—

レスポンス: 201, 400, 401, 403, 404, 405, 409, 413, 415, 422, 503, 507

例

bash
curl -X POST "$ARKVORY_URL/api/v1/repositories/$REPOSITORY/artifacts/$ID/links" \
  -H "Authorization: Bearer $ARKVORY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}'

Arkvory · ProAnimaStudio