Box Developerドキュメント
最新バージョン

Shield情報バリアのセグメントを作成

post
https://api.box.com/2.0
/shield_information_barrier_segments

このエンドポイントはバージョン2024.0です。引き続き使用するために 変更は必要ありません。詳細については、 **Box APIのバージョン管理**を参照してください。

Shield情報バリアのセグメントを作成します。

リクエスト

bearer [ACCESS_TOKEN]
application/json

リクエスト本文

string本文内省略可能
"'Corporate division that engages in advisory_based financial transactions on behalf of individuals, corporations, and governments.'"

Shield情報バリアのセグメントの説明。

string本文内必須
"Investment Banking"

Shield情報バリアのセグメントの名前。

Shield情報バリアオブジェクトのBase版の表示。

レスポンス

新しいShield情報バリアのセグメントオブジェクトを返します。

Shield情報バリアが見つからなかった場合はエラーを返します。

同じ名前のShield情報バリアのセグメントが存在する場合はエラーを返します。

予期しないクライアントエラー。

post
Shield情報バリアのセグメントを作成
このドキュメント内で一部のAPIを試せるようになりました。
ログイン

リクエストの例

sdk


TypeScript Gen
await client.shieldInformationBarrierSegments.createShieldInformationBarrierSegment(
  {
    shieldInformationBarrier: {
      id: barrierId,
      type: 'shield_information_barrier' as ShieldInformationBarrierBaseTypeField,
    } satisfies ShieldInformationBarrierBase,
    name: segmentName,
    description: segmentDescription,
  } satisfies CreateShieldInformationBarrierSegmentRequestBody,
);
Python Gen
client.shield_information_barrier_segments.create_shield_information_barrier_segment(
    ShieldInformationBarrierBase(
        id=barrier_id,
        type=ShieldInformationBarrierBaseTypeField.SHIELD_INFORMATION_BARRIER,
    ),
    segment_name,
    description=segment_description,
)
.NET Gen
await client.ShieldInformationBarrierSegments.CreateShieldInformationBarrierSegmentAsync(requestBody: new CreateShieldInformationBarrierSegmentRequestBody(shieldInformationBarrier: new ShieldInformationBarrierBase() { Id = barrierId, Type = ShieldInformationBarrierBaseTypeField.ShieldInformationBarrier }, name: segmentName) { Description = segmentDescription });
Swift Gen (Beta)
try await client.shieldInformationBarrierSegments.createShieldInformationBarrierSegment(requestBody: CreateShieldInformationBarrierSegmentRequestBody(shieldInformationBarrier: ShieldInformationBarrierBase(id: barrierId, type: ShieldInformationBarrierBaseTypeField.shieldInformationBarrier), name: segmentName, description: segmentDescription))
Java Gen (Beta)
client.getShieldInformationBarrierSegments().createShieldInformationBarrierSegment(new CreateShieldInformationBarrierSegmentRequestBody.Builder(new ShieldInformationBarrierBase.Builder().id(barrierId).type(ShieldInformationBarrierBaseTypeField.SHIELD_INFORMATION_BARRIER).build(), segmentName).description(segmentDescription).build())
Node
const barrierSegment = await client.shieldInformationBarrierSegments.create({
	name: 'barrier segment name',
	description: 'barrier segment description',
	shield_information_barrier: {
		id: '123',
		type: 'shield_information_barrier'
	},
});
console.log(`Shield information barrier segment id ${barrierSegment.id} created`);

レスポンスの例

{
  "id": "11446498",
  "type": "shield_information_barrier_segment",
  "created_at": "2020-06-26T18:44:45.869Z",
  "created_by": {
    "id": "11446498",
    "type": "user"
  },
  "description": "'Corporate division that engages in advisory_based financial\n transactions on behalf of individuals, corporations, and governments.'",
  "name": "Investment Banking",
  "shield_information_barrier": {
    "id": "11446498",
    "type": "shield_information_barrier"
  },
  "updated_at": "2020-07-26T18:44:45.869Z",
  "updated_by": {
    "id": "11446498",
    "type": "user"
  }
}