---
updatedAt: 2025-06-11T23:27:52.000Z
agentTools:
  projectIndex: https://developer.usebutton.com/llms.txt
---

# Add customers to an Audience

Adds new customer memberships to an existing Audience.

Additions may take up to 48 hours to be reflected elsewhere in Button’s systems.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "audiences-api",
    "version": "4"
  },
  "servers": [
    {
      "url": "https://api.usebutton.com/v1/audiences"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "http",
        "scheme": "basic"
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/{audience_id}/customers": {
      "post": {
        "summary": "Add customers to an Audience",
        "description": "Adds new customer memberships to an existing Audience.\n\nAdditions may take up to 48 hours to be reflected elsewhere in Button’s systems.",
        "operationId": "add-customers-to-an-existing-audience",
        "parameters": [
          {
            "name": "audience_id",
            "in": "path",
            "description": "The internal (or external, if `is_external_id` is true) ID of the Audience of interest.",
            "schema": {
              "type": "string"
            },
            "required": true
          },
          {
            "name": "is_external_id",
            "in": "query",
            "description": "Whether to treat the `audience_id` as an external ID",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "customers": {
                    "properties": {
                      "email_sha256s": {
                        "type": "string",
                        "description": "Maximum array length of 10. Must be a hex-encoded SHA-256 hash, and whitespace-trimmed and lower-cased."
                      },
                      "device_ids": {
                        "type": "string",
                        "description": "Maximum array length of 10. 32 hexadecimal characters separated by hyphens, i.e. `{8}-{4}-{4}-{4}-{12}`"
                      }
                    },
                    "required": [
                      "email_sha256s",
                      "device_ids"
                    ],
                    "type": "object",
                    "description": "Maximum array length of 5000. Each element should contain one or more IDs belonging to a single customer for your organization."
                  }
                }
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "202",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {}
                }
              }
            }
          }
        },
        "deprecated": false,
        "x-readme": {
          "code-samples": [
            {
              "language": "curl",
              "code": "curl https://api.usebutton.com/v1/audiences/{audience_id}/customers \\\n  -X POST \\\n  -u YOUR_API_KEY \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\n  customers: [\n    {\n      email_sha256s: [string],\n      device_ids: [string]\n    }\n  ]\n}'"
            }
          ],
          "samples-languages": [
            "curl"
          ]
        }
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```