Netlify Split Test API

The Split Test API from Netlify — 4 operation(s) for split test.

Business capability
A/B Test Execution BC-4280.50

Operations 6

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

POST /sites/{site_id}/traffic_splits Create a branch split test · Create split test #
Ask an LLM
“How do I A/B test two branches of my Netlify site?”
“Can I send a percentage of traffic to a different branch?”
Tell an agent
Create a split test on site {site}.
Create a split test on site {site} dividing traffic as {branches}.
GET /sites/{site_id}/traffic_splits List a site's split tests · Get split tests #
Ask an LLM
“What split tests are configured on my site?”
“Can I see how traffic is divided between branches?”
Tell an agent
List split tests for site {site}.
Show every traffic split on site {site}.
PUT /sites/{site_id}/traffic_splits/{split_test_id} Update a split test's traffic split · Update split test #
Ask an LLM
“Can I change the traffic percentages in an existing split test?”
“How do I add another branch to a running A/B test?”
Tell an agent
Update split test {test} on site {site} to {branches}.
Change traffic allocation of split test {test} on site {site}.
GET /sites/{site_id}/traffic_splits/{split_test_id} Get a split test · Get split test #
Ask an LLM
“Can I view one split test's traffic allocation?”
“Is a particular split test currently live?”
Tell an agent
Get split test {test} on site {site}.
Show the branch allocation for split test {test} of site {site}.
POST /sites/{site_id}/traffic_splits/{split_test_id}/publish Start a split test · Enable split test #
Ask an LLM
“How do I publish a split test so it starts routing traffic?”
“Can I turn on a split test I've configured?”
Tell an agent
Start split test {test} on site {site}.
Publish split test {test} for site {site}.
POST /sites/{site_id}/traffic_splits/{split_test_id}/unpublish Stop a split test · Disable split test #
Ask an LLM
“How do I end an A/B test and send all traffic back to one branch?”
“Can I pause a split test without deleting it?”
Tell an agent
Stop split test {test} on site {site}.
Unpublish split test {test} for site {site}.

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/netlify:netlify-split-test-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

netlify-split-test-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  version: 2.57.0
  title: Netlify's API documentation Split Test API
  description: Netlify is a hosting service for the programmable web.
  termsOfService: https://www.netlify.com/legal/terms-of-use/
  x-logo:
    url: netlify-logo.png
    href: https://www.netlify.com/docs/
    altText: Netlify
servers:
- url: https://api.netlify.com/api/v1
security:
- netlifyAuth: []
tags:
- name: Split Test
  x-displayName: Split test
paths:
  /sites/{site_id}/traffic_splits:
    parameters:
    - name: site_id
      in: path
      required: true
      schema:
        type: string
    post:
      operationId: createSplitTest
      tags:
      - Split Test
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                  site_id:
                    type: string
                  name:
                    type: string
                  path:
                    type: string
                  branches:
                    type: array
                    items:
                      type: object
                  active:
                    type: boolean
                  created_at:
                    type: string
                    format: dateTime
                  updated_at:
                    type: string
                    format: dateTime
                  unpublished_at:
                    type: string
                    format: dateTime
        default:
          description: error
          content:
            application/json:
              schema:
                type: object
                required:
                - message
                properties:
                  code:
                    type: integer
                    format: int64
                  message:
                    type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                branch_tests:
                  type: object
        required: true
      summary: Create split test
      x-summary-source: derived
    get:
      operationId: getSplitTests
      tags:
      - Split Test
      responses:
        '200':
          description: split_tests
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                  properties:
                    id:
                      type: string
                    site_id:
                      type: string
                    name:
                      type: string
                    path:
                      type: string
                    branches:
                      type: array
                      items:
                        type: object
                    active:
                      type: boolean
                    created_at:
                      type: string
                      format: dateTime
                    updated_at:
                      type: string
                      format: dateTime
                    unpublished_at:
                      type: string
                      format: dateTime
        default:
          description: error
          content:
            application/json:
              schema:
                type: object
                required:
                - message
                properties:
                  code:
                    type: integer
                    format: int64
                  message:
                    type: string
      summary: Get split tests
      x-summary-source: derived
  /sites/{site_id}/traffic_splits/{split_test_id}:
    parameters:
    - name: site_id
      in: path
      required: true
      schema:
        type: string
    - name: split_test_id
      in: path
      required: true
      schema:
        type: string
    put:
      operationId: updateSplitTest
      tags:
      - Split Test
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                  site_id:
                    type: string
                  name:
                    type: string
                  path:
                    type: string
                  branches:
                    type: array
                    items:
                      type: object
                  active:
                    type: boolean
                  created_at:
                    type: string
                    format: dateTime
                  updated_at:
                    type: string
                    format: dateTime
                  unpublished_at:
                    type: string
                    format: dateTime
        default:
          description: error
          content:
            application/json:
              schema:
                type: object
                required:
                - message
                properties:
                  code:
                    type: integer
                    format: int64
                  message:
                    type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                branch_tests:
                  type: object
        required: true
      summary: Update split test
      x-summary-source: derived
    get:
      operationId: getSplitTest
      tags:
      - Split Test
      responses:
        '200':
          description: split_test
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                  site_id:
                    type: string
                  name:
                    type: string
                  path:
                    type: string
                  branches:
                    type: array
                    items:
                      type: object
                  active:
                    type: boolean
                  created_at:
                    type: string
                    format: dateTime
                  updated_at:
                    type: string
                    format: dateTime
                  unpublished_at:
                    type: string
                    format: dateTime
        default:
          description: error
          content:
            application/json:
              schema:
                type: object
                required:
                - message
                properties:
                  code:
                    type: integer
                    format: int64
                  message:
                    type: string
      summary: Get split test
      x-summary-source: derived
  /sites/{site_id}/traffic_splits/{split_test_id}/publish:
    parameters:
    - name: site_id
      in: path
      required: true
      schema:
        type: string
    - name: split_test_id
      in: path
      required: true
      schema:
        type: string
    post:
      operationId: enableSplitTest
      tags:
      - Split Test
      responses:
        '204':
          description: enable
        default:
          description: error
          content:
            application/json:
              schema:
                type: object
                required:
                - message
                properties:
                  code:
                    type: integer
                    format: int64
                  message:
                    type: string
      summary: Enable split test
      x-summary-source: derived
  /sites/{site_id}/traffic_splits/{split_test_id}/unpublish:
    parameters:
    - name: site_id
      in: path
      required: true
      schema:
        type: string
    - name: split_test_id
      in: path
      required: true
      schema:
        type: string
    post:
      operationId: disableSplitTest
      tags:
      - Split Test
      responses:
        '204':
          description: disabled
        default:
          description: error
          content:
            application/json:
              schema:
                type: object
                required:
                - message
                properties:
                  code:
                    type: integer
                    format: int64
                  message:
                    type: string
      summary: Disable split test
      x-summary-source: derived
components:
  securitySchemes:
    netlifyAuth:
      type: oauth2
      flows:
        implicit:
          scopes: {}
          authorizationUrl: https://app.netlify.com/authorize
externalDocs:
  url: https://www.netlify.com/docs/api/
  description: Online documentation
x-tagGroups:
- name: OAuth
  tags:
  - ticket
  - accessToken
- name: User accounts
  tags:
  - user
  - accountMembership
  - member
  - accountType
  - paymentMethod
  - auditLog
- name: Site
  tags:
  - site
  - environmentVariables
  - file
  - metadata
  - purge
  - snippet
- name: Domain names
  tags:
  - dnsZone
  - sniCertificate
- name: Deploys
  tags:
  - deploy
  - deployedBranch
  - deployKey
- name: Builds
  tags:
  - build
  - buildLogMsg
- name: Dev servers
  tags:
  - devServer
- name: Webhooks and notifications
  tags:
  - hook
  - hookType
  - buildHook
  - devServerHook
- name: Services
  tags:
  - service
  - serviceInstance
- name: Functions
  tags:
  - function
- name: Database
  tags:
  - database
- name: Forms
  tags:
  - form
  - submission
- name: Split tests
  tags:
  - splitTest
- name: Large media
  tags:
  - asset
  - assetPublicSignature