CoreStory Billing API

The billing API from CoreStory — 4 operation(s) for billing.

Business capability
Invoicing & Statement Management BC-4250.30

Operations 4

POST /api/billing/checkout-session Create Stripe Checkout session #
POST /api/billing/portal-session Create Stripe Customer Portal session #
GET /api/billing/invoices List past invoices #
GET /api/billing/upcoming-invoice Preview upcoming invoice #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/corestory-billing-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

corestory-billing-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Crowdbotics API Documentation Billing API
  description: '# CoreStory API Overview


    The CoreStory API provides programmatic access to structured insights derived from software source code.'
  version: 1.26.2
servers:
- url: /
  description: Current server
security:
- BearerAuth: []
tags:
- name: Billing
paths:
  /api/billing/checkout-session:
    post:
      tags:
      - Billing
      summary: Create Stripe Checkout session
      description: Start a Stripe Checkout flow to subscribe the organization to the Pro plan.
      operationId: create_checkout_session
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BillingSessionResponse'
        default:
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorSchema'
  /api/billing/portal-session:
    post:
      tags:
      - Billing
      summary: Create Stripe Customer Portal session
      description: Open the Stripe Customer Portal for the organization to manage their subscription.
      operationId: create_portal_session
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BillingSessionResponse'
        default:
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorSchema'
  /api/billing/invoices:
    get:
      tags:
      - Billing
      summary: List past invoices
      description: Return past Stripe invoices for the organization. Admin only.
      operationId: list_invoices
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvoiceListResponse'
        default:
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorSchema'
  /api/billing/upcoming-invoice:
    get:
      tags:
      - Billing
      summary: Preview upcoming invoice
      description: Return a preview of the next Stripe invoice for the organization. Admin only.
      operationId: get_upcoming_invoice
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UpcomingInvoiceResponse'
        default:
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorSchema'
components:
  schemas:
    ErrorSchema:
      properties:
        error:
          $ref: '#/components/schemas/ErrorBody'
      type: object
      required:
      - error
      title: ErrorSchema
    UpcomingInvoiceResponse:
      properties:
        upcoming_invoice:
          anyOf:
          - $ref: '#/components/schemas/UpcomingInvoiceDetail'
          - type: 'null'
          description: Upcoming invoice preview, or null if not applicable
      type: object
      title: UpcomingInvoiceResponse
      description: Response for the upcoming invoice endpoint. Null when no active Stripe subscription.
    UpcomingInvoiceLineItem:
      properties:
        description:
          anyOf:
          - type: string
          - type: 'null'
          title: Description
          description: Line item description
        amount:
          type: integer
          title: Amount
          description: Amount in smallest currency unit (e.g. cents)
      type: object
      required:
      - amount
      title: UpcomingInvoiceLineItem
      description: A single line item on an upcoming invoice.
    UpcomingInvoiceDetail:
      properties:
        amount_due:
          type: integer
          title: Amount Due
          description: Total amount due in smallest currency unit
        currency:
          type: string
          title: Currency
          description: Three-letter ISO currency code
        period_start:
          type: string
          format: date-time
          title: Period Start
          description: Start of the billing period
        period_end:
          type: string
          format: date-time
          title: Period End
          description: End of the billing period
        lines:
          items:
            $ref: '#/components/schemas/UpcomingInvoiceLineItem'
          type: array
          title: Lines
          description: Invoice line items
      type: object
      required:
      - amount_due
      - currency
      - period_start
      - period_end
      title: UpcomingInvoiceDetail
      description: Preview of the next Stripe invoice.
    InvoiceResponse:
      properties:
        id:
          type: string
          title: Id
          description: Stripe invoice ID
        number:
          anyOf:
          - type: string
          - type: 'null'
          title: Number
          description: Human-readable invoice number
        status:
          anyOf:
          - type: string
          - type: 'null'
          title: Status
          description: Invoice status (paid, open, draft, etc.)
        amount_due:
          type: integer
          title: Amount Due
          description: Amount due in smallest currency unit (e.g. cents)
        amount_paid:
          type: integer
          title: Amount Paid
          description: Amount paid in smallest currency unit
        currency:
          type: string
          title: Currency
          description: Three-letter ISO currency code
        created:
          type: string
          format: date-time
          title: Created
          description: When the invoice was created
        hosted_invoice_url:
          anyOf:
          - type: string
          - type: 'null'
          title: Hosted Invoice Url
          description: URL to the hosted invoice page
        invoice_pdf:
          anyOf:
          - type: string
          - type: 'null'
          title: Invoice Pdf
          description: URL to the invoice PDF
      type: object
      required:
      - id
      - amount_due
      - amount_paid
      - currency
      - created
      title: InvoiceResponse
      description: A single Stripe invoice.
    InvoiceListResponse:
      properties:
        invoices:
          items:
            $ref: '#/components/schemas/InvoiceResponse'
          type: array
          title: Invoices
      type: object
      required:
      - invoices
      title: InvoiceListResponse
      description: List of invoices for an organization.
    BillingSessionResponse:
      properties:
        url:
          type: string
          maxLength: 2083
          minLength: 1
          format: uri
          title: Url
      type: object
      required:
      - url
      title: BillingSessionResponse
      description: Response containing a Stripe session URL (checkout or portal).
    ErrorBody:
      properties:
        message:
          type: string
          title: Message
        type:
          type: string
          title: Type
        details:
          additionalProperties: true
          type: object
          title: Details
          description: Optional extra context for the error.
      type: object
      required:
      - message
      - type
      title: ErrorBody
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Enter the Bearer token from Clerk authentication
x-tagGroups:
- name: Ingest Your Codebase
  tags:
  - vector_store
  - projects
  - pre_ingestion
  - reingestion
- name: Generate Code Intelligence
  tags:
  - documents
  - document_generation
  - document_formatters
  - prd
  - prd_version
  - tech_spec
  - quality_metrics
  - sample_projects
- name: Query Your Codebase
  tags:
  - conversations
  - workflows
  - discovery
  - context
  - artifacts
- name: Manage and Inspect Intelligence
  tags:
  - api_debugging
  - events
  - version
  - files
  - cache
  - token_tracking
- name: Authenticate and Manage Access
  tags:
  - clerk_authentication
  - github_webhooks
  - github_integration
  - organizations
  - api_key_management
  - mcp_token_management
  - user
- name: (Advanced) Prompt Tuning
  tags:
  - prompts
- name: MCP Protocol
  tags:
  - mcp_protocol
- name: Administration
  tags:
  - admin