---
title: "Join the coding plan, or change your monthly amount [write]"
method: POST
path: "/billing/coding-plan"
---

# Join the coding plan, or change your monthly amount \[write\]

`POST /billing/coding-plan`

## Request

- Base URL: `https://api.agentsky.dev/v1`
- URL: `https://api.agentsky.dev/v1/billing/coding-plan`
- Auth: none declared

Joining charges the caller's saved card amount_usd plus the card processing fee and adds amount_usd as purchased credit; the plan renews monthly on the same card. A current member's call changes the amount from the next renewal, charges nothing, and undoes a pending cancellation. request_id makes a repeat of the same join charge once. 409 card_required without a saved card (POST /billing/card-setup adds one), 402 card_declined, 403 enrollment_closed, 409 enrollment_full, 409 charge_in_progress, 503 payments_unavailable. A workspace key or a restricted credential cannot change the plan.

## Request body

- object
  - `amount_usd` 10 | 40, required
  - `request_id` string, required

## Response `200`

The plan after the change

- CodingPlan
  - `active` boolean, required: A paid month covers now
  - `monthly_credit_usd` number, nullable, required
  - `current_period_end` string, date-time, nullable, required
  - `renews` boolean, required: The plan charges again at current_period_end
  - `charge_failure` string, nullable, required: Why the last charge failed, worded for the cardholder
  - `enrollment` 'open' | 'full' | 'closed', required
  - `amounts_usd` number[], required

## Other responses

- `default`: Error — { error: { code, message, request_id } }

## Changes

- **2026-11-02** `e5e8f0229a99`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/agentsky/apis/agentsky-developer-api/changes/billing/coding-plan/post.md)

---

[API](https://skmtc.dev/agentsky/apis/agentsky-developer-api.md) - [All operations](https://skmtc.dev/agentsky/apis/agentsky-developer-api/llms.txt) - [OpenAPI document](https://skmtc.dev/agentsky/apis/agentsky-developer-api/revisions/0d435187cd55?raw)
