{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-index.sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["admonition"]},"type":"markdown"},"seo":{"title":"Create an API Key","llmstxt":{"hide":false,"sections":[{"title":"Table of contents","includeFiles":["**/*"],"excludeFiles":[]}],"excludeFiles":[]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"create-an-api-key","__idx":0},"children":["Create an API Key"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"use-api-keys-to-authenticate-your-api-requests","__idx":1},"children":["Use API keys to authenticate your API requests."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Anesya authenticates API requests with an API key linked to your account.",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"If a request does not include a valid key, Anesya will return an ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/api/schema/section/common-error-codes"},"children":["authentication error (401)"]},".",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"If a request contains a deleted or expired key, the same error will be raised."]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["To create, delete, or renew API keys, use the ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://dashboard.anesya.app/api"},"children":["Anesya Dashboard"]},".",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"You can find your API keys under the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["My Account"]}," tab, then ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["API"]}," in your dashboard."]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"token-management","__idx":2},"children":["Token management"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["You can create your token on the Anesya Dashboard.",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Expiration and renewal options are managed directly from the dashboard."]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info","name":"Important"},"children":[{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Do not share your tokens and never commit them to GitHub."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Once created, your token cannot be viewed again — make sure to copy and store it safely."]}]}]}]},"headings":[{"value":"Create an API Key","id":"create-an-api-key","depth":1},{"value":"Use API keys to authenticate your API requests.","id":"use-api-keys-to-authenticate-your-api-requests","depth":3},{"value":"Token management","id":"token-management","depth":3}],"frontmatter":{"seo":{"title":"Create an API Key"}},"lastModified":"2026-04-22T15:07:29.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/tutorials/api_key","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}