Couchbase Functions API

Endpoints for creating, retrieving, updating, and deleting Eventing Functions.

Operations 4

GET /api/v1/functions List all Eventing Functions #
GET /api/v1/functions/{functionName} Get an Eventing Function #
POST /api/v1/functions/{functionName} Create or update an Eventing Function #
DELETE /api/v1/functions/{functionName} Delete an Eventing Function #

Documentation

Specifications

Other Resources

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/couchbase-functions-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

couchbase-functions-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Couchbase Eventing Service REST Functions API
  description: The Couchbase Eventing Service REST API provides methods for deploying and managing Eventing Functions that respond to data changes in real time. Eventing Functions allow developers to write server-side JavaScript logic triggered by document mutations, timers, or external events. The API supports creating, deploying, pausing, and undeploying functions, as well as monitoring their execution status and statistics.
  version: '7.6'
  contact:
    name: Couchbase Support
    url: https://support.couchbase.com
  termsOfService: https://www.couchbase.com/terms-of-use
servers:
- url: https://localhost:8096
  description: Eventing Service (default port)
- url: https://localhost:18096
  description: Eventing Service (SSL)
security:
- basicAuth: []
tags:
- name: Functions
  description: Endpoints for creating, retrieving, updating, and deleting Eventing Functions.
paths:
  /api/v1/functions:
    get:
      operationId: listEventingFunctions
      summary: List all Eventing Functions
      description: Returns the definitions of all Eventing Functions including their source code, bindings, and deployment settings.
      tags:
      - Functions
      responses:
        '200':
          description: Successful retrieval of function list
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/EventingFunction'
        '401':
          description: Unauthorized access
  /api/v1/functions/{functionName}:
    get:
      operationId: getEventingFunction
      summary: Get an Eventing Function
      description: Returns the definition of a specific Eventing Function including its source code, bindings, and deployment settings.
      tags:
      - Functions
      parameters:
      - $ref: '#/components/parameters/functionName'
      responses:
        '200':
          description: Successful retrieval of function definition
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EventingFunction'
        '401':
          description: Unauthorized access
        '404':
          description: Function not found
    post:
      operationId: createOrUpdateEventingFunction
      summary: Create or update an Eventing Function
      description: Creates a new Eventing Function or updates an existing one with the provided definition. The function name in the URL must match the appname in the request body.
      tags:
      - Functions
      parameters:
      - $ref: '#/components/parameters/functionName'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EventingFunction'
      responses:
        '200':
          description: Function created or updated successfully
        '400':
          description: Invalid function definition
        '401':
          description: Unauthorized access
    delete:
      operationId: deleteEventingFunction
      summary: Delete an Eventing Function
      description: Deletes the specified Eventing Function. Only functions in undeployed state can be deleted.
      tags:
      - Functions
      parameters:
      - $ref: '#/components/parameters/functionName'
      responses:
        '200':
          description: Function deleted successfully
        '401':
          description: Unauthorized access
        '404':
          description: Function not found
        '422':
          description: Function is deployed and cannot be deleted
components:
  parameters:
    functionName:
      name: functionName
      in: path
      required: true
      description: The name of the Eventing Function
      schema:
        type: string
  schemas:
    EventingFunction:
      type: object
      description: Eventing Function definition
      required:
      - appname
      - appcode
      properties:
        appname:
          type: string
          description: Name of the Eventing Function
        appcode:
          type: string
          description: JavaScript handler code for the function
        depcfg:
          type: object
          description: Dependency configuration including bindings
          properties:
            buckets:
              type: array
              description: Bucket bindings for the function
              items:
                type: object
                properties:
                  alias:
                    type: string
                    description: Alias name used in handler code
                  bucket_name:
                    type: string
                    description: Name of the bound bucket
                  scope_name:
                    type: string
                    description: Name of the scope
                  collection_name:
                    type: string
                    description: Name of the collection
                  access:
                    type: string
                    description: Access level for the bucket binding
                    enum:
                    - r
                    - rw
            curl:
              type: array
              description: cURL bindings for external HTTP calls
              items:
                type: object
                properties:
                  hostname:
                    type: string
                    description: URL of the external endpoint
                  value:
                    type: string
                    description: Alias name used in handler code
                  auth_type:
                    type: string
                    description: Authentication type
                    enum:
                    - no-auth
                    - basic
                    - bearer
                    - digest
                  allow_cookies:
                    type: boolean
                    description: Whether to allow cookies
                  validate_ssl_certificate:
                    type: boolean
                    description: Whether to validate SSL certificates
            constants:
              type: array
              description: Constant bindings
              items:
                type: object
                properties:
                  value:
                    type: string
                    description: Alias name
                  literal:
                    type: string
                    description: Constant value
            source_bucket:
              type: string
              description: Source bucket for mutations
            source_scope:
              type: string
              description: Source scope for mutations
            source_collection:
              type: string
              description: Source collection for mutations
            metadata_bucket:
              type: string
              description: Metadata bucket for checkpoints
            metadata_scope:
              type: string
              description: Metadata scope for checkpoints
            metadata_collection:
              type: string
              description: Metadata collection for checkpoints
        settings:
          type: object
          description: Function deployment settings
          properties:
            dcp_stream_boundary:
              type: string
              description: Starting point for processing mutations
              enum:
              - everything
              - from_now
            deployment_status:
              type: boolean
              description: Whether the function is deployed
            processing_status:
              type: boolean
              description: Whether the function is processing mutations
            log_level:
              type: string
              description: Log level for the function
              enum:
              - INFO
              - ERROR
              - WARNING
              - DEBUG
              - TRACE
            language_compatibility:
              type: string
              description: Language compatibility version
            execution_timeout:
              type: integer
              description: Maximum execution time for a single handler invocation in seconds
            timer_context_size:
              type: integer
              description: Maximum size of timer context in bytes
            worker_count:
              type: integer
              description: Number of worker threads
            num_timer_partitions:
              type: integer
              description: Number of timer partitions
        function_scope:
          type: object
          description: Scope of the function definition
          properties:
            bucket:
              type: string
              description: Bucket for the function scope
            scope:
              type: string
              description: Scope name
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
      description: HTTP Basic Authentication using Couchbase Server credentials.
externalDocs:
  description: Couchbase Eventing Service REST API Documentation
  url: https://docs.couchbase.com/server/current/eventing/eventing-api.html