generated: '2026-07-17' method: searched source: >- https://forum.astroprint.com/t/how-to-request-oauth-2-token-through-api/4384 and the AstroPrint developer portal (https://developer.astroprint.com). Confirmed live: https://api.astroprint.com/v2/printers returns HTTP 401 without a token. No public OpenAPI is published, so this profile is captured from the developer documentation rather than derived from a spec. description: >- AstroPrint Cloud API authentication. The API is protected by OAuth 2.0. Apps are registered on the AstroPrint developer/development page to obtain a client_id and client_secret, then exchange them at the token endpoint. Both the client_credentials grant and the authorization_code grant are documented; the authorization_code (three-legged) flow is required for full access to a user's printers and designs, while client_credentials returns an empty dataset for user-scoped resources. summary: types: - oauth2 base_url: https://api.astroprint.com/v2 schemes: - name: oauth2 type: oauth2 description: >- OAuth 2.0. Register an app on the AstroPrint developer page to receive a client_id/client_secret plus the authorization and token URLs. Access tokens are sent as a Bearer token on API requests. token_endpoint: https://api.astroprint.com/v2/token grants: - client_credentials - authorization_code scopes: [] scopes_note: >- The developer documentation references scope selection during OAuth app setup, but AstroPrint does not publish a public enumerated scope reference, so no scope list is captured here (absence recorded, not fabricated). docs: https://developer.astroprint.com/ evidence: - https://api.astroprint.com/v2/printers returned HTTP 401 (auth required) at probe time - https://forum.astroprint.com/t/how-to-request-oauth-2-token-through-api/4384