---
title: "Claim Resource"
method: POST
path: "/api/v1/resource-claims/{subscriptionId}/claim"
tags: ["Resource Claims"]
---

# Claim Resource

`POST /api/v1/resource-claims/{subscriptionId}/claim`

Claim a resource for a subscription. Exactly one of quantity, externalId, or externalIds must be provided.

## Path parameters

- `subscriptionId` string, required

## Request body

- object
  - `resourceSlug` string, required — The slug of the resource to claim
  - `metadata` Metadata — JSON object
  - `quantity` integer — Create N anonymous claims without external identifiers.
  - `externalId` string — Create a single named claim with this external identifier (idempotent).
  - `externalIds` string[] — Create multiple named claims with these external identifiers (idempotent per ID).

## Response `200`

Successful response

- object
  - `claims` ResourceClaimClientSelectSchema[], required
    - `id` string, required
    - `createdAt` integer, required — Epoch milliseconds.
    - `updatedAt` integer, required — Epoch milliseconds.
    - `livemode` boolean, required
    - `organizationId` string, required
    - `subscriptionItemFeatureId` string, required
    - `resourceId` string, required
    - `subscriptionId` string, required
    - `pricingModelId` string, required
    - `externalId` string, nullable, required
    - `claimedAt` integer, required — Epoch milliseconds.
    - `releasedAt` integer, nullable — Epoch milliseconds.
    - `releaseReason` string, nullable, required
    - `metadata` Metadata — JSON object
  - `usage` object, required
    - `resourceSlug` string, required
    - `resourceId` string, required
    - `capacity` integer, required
    - `claimed` integer, required
    - `available` integer, required

## Other responses

- `400` — Invalid input data
- `401` — Authorization not provided
- `403` — Insufficient access
- `500` — Internal server error

## Changes

- **2026-01-14** `7fcbd2dbf3c1` — 2 info
  - added the required property `usage/resourceId` to the response with the `200` status
  - added the required property `usage/resourceSlug` to the response with the `200` status
- **2026-01-11** `599bbd902d65` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/flowglad/apis/flowglad-api/changes/api/v1/resource-claims/:subscriptionId/claim/post.md)

---

[API](https://skmtc.dev/flowglad/apis/flowglad-api.md) · [All operations](https://skmtc.dev/flowglad/apis/flowglad-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/flowglad/flowglad-api/revisions/06c4dd78e137/schema)
