Creates a new Security instance with a GitHub personal access token.
A GitHub personal access token (e.g., ghp_...) or OAuth token
The base URL of the GitHub API. Defaults to 'https://api.github.com'.
Must be a valid URL; throws if it cannot be parsed.
Returns the base URL of the GitHub API, without a trailing slash.
The API base URL
Returns the value of the Authorization header for Bearer authentication.
The Authorization header value in the format Bearer <token>
Returns the full set of HTTP headers required for authenticated GitHub API requests.
An object containing Authorization, Accept, Content-Type, and X-GitHub-Api-Version headers
Returns headers for raw file content requests.
Headers with Accept: application/vnd.github.raw+json
Handles Bearer token authentication for GitHub REST API requests.
Example