[{"data":1,"prerenderedAt":22},["ShallowReactive",2],{"docs-content:authentication":3},{"html":4,"toc":5},"\u003Ch1>Authentication\u003C/h1>\n\u003Cp>All \u003Ccode>/v1/\u003C/code> endpoints require an API key. JWT session tokens (used by the web app) are \u003Cstrong>not\u003C/strong> accepted on the v1 API.\u003C/p>\n\u003Ch2 id=\"getting-your-api-key\">Getting Your API Key\u003C/h2>\n\u003Col>\n\u003Cli>Sign in to your \u003Ca href=\"https://app.aivsrank.com/auth/login\">AIvsRank account\u003C/a>\u003C/li>\n\u003Cli>Navigate to \u003Cstrong>Profile → API Keys\u003C/strong>\u003C/li>\n\u003Cli>Click \u003Cstrong>Generate New Key\u003C/strong>\u003C/li>\n\u003Cli>Copy the key immediately — it is only shown once\u003C/li>\n\u003C/ol>\n\u003Cp>Keys use the prefix \u003Ccode>gly_\u003C/code> to distinguish them from other credentials.\u003C/p>\n\u003Ch2 id=\"using-your-api-key\">Using Your API Key\u003C/h2>\n\u003Cp>Pass the key in the \u003Ccode>Authorization\u003C/code> header using the \u003Ccode>Bearer\u003C/code> scheme:\u003C/p>\n\u003Cpre>\u003Ccode class=\"language-bash\">curl https://api.aivsrank.com/v1/credits/balance \\\n  -H &quot;Authorization: Bearer gly_your_key_here&quot;\n\u003C/code>\u003C/pre>\n\u003Ch2 id=\"scopes\">Scopes\u003C/h2>\n\u003Cp>Each API key is issued with one or more scopes. A request missing the required scope returns \u003Ccode>403\u003C/code>.\u003C/p>\n\u003Ctable>\n\u003Cthead>\n\u003Ctr>\n\u003Cth>Scope\u003C/th>\n\u003Cth>Access\u003C/th>\n\u003C/tr>\n\u003C/thead>\n\u003Ctbody>\u003Ctr>\n\u003Ctd>\u003Ccode>brand:read\u003C/code>\u003C/td>\n\u003Ctd>Read legacy brand visibility records\u003C/td>\n\u003C/tr>\n\u003Ctr>\n\u003Ctd>\u003Ccode>leaderboard:read\u003C/code>\u003C/td>\n\u003Ctd>Read leaderboard data\u003C/td>\n\u003C/tr>\n\u003Ctr>\n\u003Ctd>\u003Ccode>credit:read\u003C/code>\u003C/td>\n\u003Ctd>Read credit balance\u003C/td>\n\u003C/tr>\n\u003C/tbody>\u003C/table>\n\u003Ch2 id=\"error-responses\">Error Responses\u003C/h2>\n\u003Ctable>\n\u003Cthead>\n\u003Ctr>\n\u003Cth>Code\u003C/th>\n\u003Cth>Reason\u003C/th>\n\u003C/tr>\n\u003C/thead>\n\u003Ctbody>\u003Ctr>\n\u003Ctd>\u003Ccode>401\u003C/code>\u003C/td>\n\u003Ctd>Missing or invalid API key\u003C/td>\n\u003C/tr>\n\u003Ctr>\n\u003Ctd>\u003Ccode>403\u003C/code>\u003C/td>\n\u003Ctd>Key is valid but lacks the required scope\u003C/td>\n\u003C/tr>\n\u003C/tbody>\u003C/table>\n\u003Cpre>\u003Ccode class=\"language-json\">{\n  &quot;code&quot;: 401,\n  &quot;message&quot;: &quot;Unauthorized&quot;,\n  &quot;data&quot;: null,\n  &quot;success&quot;: false,\n  &quot;timestamp&quot;: 1710154200000\n}\n\u003C/code>\u003C/pre>\n\u003Ch2 id=\"revoking-a-key\">Revoking a Key\u003C/h2>\n\u003Cp>Go to \u003Cstrong>Profile → API Keys\u003C/strong> and click \u003Cstrong>Revoke\u003C/strong>. The key stops working immediately.\u003C/p>\n",[6,10,13,16,19],{"id":7,"text":8,"level":9},"getting-your-api-key","Getting Your API Key",2,{"id":11,"text":12,"level":9},"using-your-api-key","Using Your API Key",{"id":14,"text":15,"level":9},"scopes","Scopes",{"id":17,"text":18,"level":9},"error-responses","Error Responses",{"id":20,"text":21,"level":9},"revoking-a-key","Revoking a Key",1782847930923]