API Evangelist API Evangelist
API Learnings
Toolbox
API Evangelist LLC

Anthropic Token Counting API

Count the number of tokens in a Message, including tools, images, and documents, without creating it. The Token Count API accepts the same structured list of inputs for creating a message, including support for system prompts, tools, images, and PDFs. Token counting is free to use but subject to requests per minute rate limits.

Documentation

Specifications

OpenAPI

anthropic-token-counting-api-openapi.yml Raw ↑