S

sourcehut.org

SourceHut is a hosted suite of software development tools including Git and Mercurial hosting, continuous integration, mailing lists, ticket tracking, static site hosting, and account management services. It operates as a set of related `*.sr.ht` services under the SourceHut platform.

2 integrations · GraphQL · CLI

SourceHut exposes a multi-service GraphQL API surface (one `/query` endpoint per service host such as `meta.sr.ht`, `git.sr.ht`, `builds.sr.ht`, `pages.sr.ht`, etc.) authenticated with SourceHut personal access tokens or OAuth 2.0 bearer tokens, plus the `hut` CLI for command-line access.

discovered 2mo ago
GraphQL1
CLI1
  • hutdiscoveredhut
Credentials
SourceHut personal access tokenbearer$ hut init

Acquired by the CLI — running hut init opens the auth flow and stores the credential.

SourceHut OAuth 2.0 client (client ID + client secret)oauth2Set up OAuth

Register an OAuth 2.0 client at meta.sr.ht OAuth settings. SourceHut issues a client ID and client secret there. Then send the user through the authorization flow described in OAuth 2.0 via meta.sr.ht: authorize at https://meta.sr.ht/oauth2/authorize with an explicit scope, then exchange the code at https://meta.sr.ht/oauth2/access-token. SourceHut supports confidential clients only; the registered redirect URI is fixed and redirect_uri must not be sent per their docs.

hut CLI login sessionoauth2$ hut init

Acquired by the CLI — running hut init opens the auth flow and stores the credential.

conventions · 0/8 published

Publish these signals → /publishing