---
title: "POST /v1/me/apikeys"
method: POST
path: "/v1/me/apikeys"
tags: ["UserAPIKeyService"]
---

# POST /v1/me/apikeys

`POST /v1/me/apikeys`

## Request body

- ApikeyV1CreateAPIKeyRequest
  - `billingMode` string — billing_mode: "" | "wallet" | "subscription"。空字符串视为 "wallet"。
  - `expiresAt` string, date-time
  - `name` string
  - `scopes` string[]
  - `subscriptionId` string — subscription_id: billing_mode="subscription" 时必须传，指定绑定的订阅 ID。
  - `teamId` string — team_id: 在团队令牌页创建时传，将令牌快照归属到该团队（创建人须为该团队 active 成员）。 个人令牌不传；订阅令牌不可带 team_id。

## Response `200`

OK

- ApikeyV1CreateAPIKeyReply
  - `apikey` ApikeyV1APIKeyInfo — APIKeyInfo API Key 元数据；plaintext key 仅在 Create/Rotate 时一次性返回。
    - `billingMode` string
    - `channelSourceCode` string
    - `channelSourceId` string
    - `createdAt` string, date-time
    - `creatorId` string
    - `creatorName` string
    - `expiresAt` string, date-time
    - `id` string
    - `keyPrefix` string
    - `lastUsedAt` string, date-time
    - `lastUsedIp` string
    - `name` string
    - `scopes` string[]
    - `status` integer
    - `subscriptionId` string
    - `teamId` string
    - `teamName` string
    - `updatedAt` string, date-time
    - `userId` string
  - `plaintextKey` string — plaintext_key 完整明文 key，仅在创建时返回一次，丢失需 rotate 重建。

---

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