billing
Get public plans (no auth required)
Returns subscription plans available for the project. Public; no authentication required. Use for pricing pages and checkout flow.
GET
/api/billing/public/projects/{projectId}/plansAuthentication
Public — No Auth Required
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
projectId | string | Yes | Project ID (MongoDB ObjectId) to list plans for. |
SDK setup
Create a client instance. No authentication is required for this endpoint.
import { MudbaseClient } from "mudbase";
const client = new MudbaseClient();import { MudbaseClient } from "mudbase";
const client = new MudbaseClient();Example request
Call this endpoint using the client from SDK setup. Use View HTTP for a raw cURL example.
const result = await client.billing.getPublicPlans({
projectId: "proj_mPAL3pJ5Ue9V"
});const result = await client.billing.getPublicPlans({
projectId: "proj_mPAL3pJ5Ue9V"
});Try It Live
Test this endpoint with your own credentials. Your requests will be sent to the live API.
No Request Yet
Send a request to see the full inspector
Responses
200Public plans list
json
{
"plans": [
{
"_id": "65a1b2c3d4e5f6789012345d",
"name": "Pro Plan",
"price": 29.99,
"currency": "USD",
"interval": "month",
"features": [
"Unlimited API calls"
]
}
]
}{
"plans": [
{
"_id": "65a1b2c3d4e5f6789012345d",
"name": "Pro Plan",
"price": 29.99,
"currency": "USD",
"interval": "month",
"features": [
"Unlimited API calls"
]
}
]
}401Authentication required or invalid token.
403Access denied or insufficient permissions.
Errors
| Code | Meaning |
|---|---|
401 | Authentication required or invalid token. |
403 | Access denied or insufficient permissions. |