Commet
  • Precios
Iniciar SesiónRegistrarse
Add feature to plan POSTAdd price to plan POSTCreate plan POSTDelete plan price DELETEDelete plan DELETEDelete regional prices DELETEGet plan GETList plans GETRemove feature from plan DELETESet default price PUTSet plan visibility PUTUpdate plan feature PUTUpdate plan price PUTUpdate plan PUTUpsert regional prices PUT
DocumentaciónRecursosConstruir con AIAPI ReferenceWebhooks

Add feature to plan

Attach a feature to a plan with limits, overage, and credits configuration.

Update plan group PUT

Update a plan group's name, description, or visibility.

Add price to plan POST

Add a billing interval price to a plan with optional trial days and included balance/credits.

POST
/plans/{id}/features

Authorization

ApiKeyAuth
x-api-key<token>

In: header

Path Parameters

id*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

featureId*string
Length1 <= length
enabled?boolean
Defaulttrue
includedAmount?integer
Default0
Range0 <= value
unlimited?boolean
Defaultfalse
overageEnabled?boolean
Defaultfalse
overageUnitPrice?integer
Default0
Range0 <= value
creditsPerUnit?|

Response Body

application/json

application/json

curl -X POST "https://commet.co/api/v1/plans/string/features" \  -H "Content-Type: application/json" \  -d '{    "featureId": "string"  }'

application/json

Public ID of the feature

Attach a feature to a plan with limits, overage, and credits configuration.

Plan public ID

{
  "success": true,
  "data": {
    "object": "plan",
    "livemode": true,
    "planId": "string",
    "featureId": "string",
    "enabled": true,
    "includedAmount": 0,
    "unlimited": true,
    "overageEnabled"



{
  "success": false,
  "error": {
    "type": "validation_error",
    "code": "string",
    "message": "string",
    "doc_url": "string",
    "param": "string"
  }
}
{
  "success": false,
  "error": {
    "type": "validation_error",
    "code": "string",
    "message": "string",
    "doc_url": "string",
    "param": "string"
  }
}
:
true
,
"overageUnitPrice": 0,
"creditsPerUnit": 0
}
}