# OAuth Scopes ## List OAuth Scopes **get** `/oauth/scopes` List all available OAuth scopes. This endpoint requires authentication but has no authorization role requirements. ### Returns - `errors: array of object { code, message, documentation_url, source }` - `code: number` - `message: string` - `documentation_url: optional string` - `source: optional object { pointer }` - `pointer: optional string` - `messages: array of object { code, message, documentation_url, source }` - `code: number` - `message: string` - `documentation_url: optional string` - `source: optional object { pointer }` - `pointer: optional string` - `success: true` Whether the API call was successful. - `true` - `result: optional array of object { id, name, category, scopes }` - `id: string` The scope label to use in the scopes array when creating or updating an OAuth client. - `name: string` Human-readable name of the OAuth scope. - `category: optional string` Category for grouping scopes in the UI. - `scopes: optional array of string` The underlying resource scopes (Bach scopes) that define which resources this OAuth scope can act upon. - `result_info: optional object { count, page, per_page, total_count }` - `count: optional number` Total number of results for the requested service - `page: optional number` Current page within paginated list of results - `per_page: optional number` Number of results per page of results - `total_count: optional number` Total results available without any search parameters ### Example ```http curl https://api.cloudflare.com/client/v4/oauth/scopes \ -H "Authorization: Bearer $CLOUDFLARE_API_TOKEN" ``` #### Response ```json { "errors": [ { "code": 1000, "message": "message", "documentation_url": "documentation_url", "source": { "pointer": "pointer" } } ], "messages": [ { "code": 1000, "message": "message", "documentation_url": "documentation_url", "source": { "pointer": "pointer" } } ], "success": true, "result": [ { "id": "account.read", "name": "Account Read", "category": "account_and_billing", "scopes": [ "com.cloudflare.api.account" ] } ], "result_info": { "count": 1, "page": 1, "per_page": 20, "total_count": 2000 } } ``` ## Domain Types ### OAuth Scope List Response - `OAuthScopeListResponse object { id, name, category, scopes }` An available OAuth scope that can be assigned to an OAuth client. - `id: string` The scope label to use in the scopes array when creating or updating an OAuth client. - `name: string` Human-readable name of the OAuth scope. - `category: optional string` Category for grouping scopes in the UI. - `scopes: optional array of string` The underlying resource scopes (Bach scopes) that define which resources this OAuth scope can act upon.