Fixes #264. Adds endpoints: ``` /v0/auth/github # exchange a github token for a registry token that gives you access to namespaces io.github.username and io.github.org for your orgs /v0/auth/none # get a registry token for namespace io.modelcontextprotocol.anonymous (only for testing/local dev purposes) ``` Updates `/v0/publish` to accept one of these registry tokens. ## Motivation and Context See #264 ## How Has This Been Tested? - Running locally and getting a token from `/v0/auth/none` and then publishing to `/v0/publish` - Updating the integration tests that get a token and then publish, and them passing ## Breaking Changes This is a breaking change to the auth API. This is fine for registry given it's not deployed yet. ## Types of changes <!-- What types of changes does your code introduce? Put an `x` in all the boxes that apply: --> - [ ] Bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds functionality) - [x] Breaking change (fix or feature that would cause existing functionality to change) - [x] Documentation update ## Checklist <!-- Go over all the following points, and put an `x` in all the boxes that apply. --> - [x] I have read the [MCP Documentation](https://modelcontextprotocol.io) - [x] My code follows the repository's style guidelines - [x] New and existing tests pass locally - [x] I have added appropriate error handling - [x] I have added or updated documentation as needed ## Additional context <!-- Add any other context, implementation notes, or design decisions --> --------- Co-authored-by: claude[bot] <209825114+claude[bot]@users.noreply.github.com> Co-authored-by: adam jones <domdomegg@users.noreply.github.com>
33 lines
1.2 KiB
Modula-2
33 lines
1.2 KiB
Modula-2
module github.com/modelcontextprotocol/registry
|
|
|
|
go 1.24.0
|
|
|
|
require (
|
|
github.com/caarlos0/env/v11 v11.3.1
|
|
github.com/danielgtaylor/huma/v2 v2.34.1
|
|
github.com/google/uuid v1.6.0
|
|
github.com/santhosh-tekuri/jsonschema/v5 v5.3.1
|
|
github.com/stretchr/testify v1.10.0
|
|
go.mongodb.org/mongo-driver v1.17.3
|
|
)
|
|
|
|
require (
|
|
github.com/davecgh/go-spew v1.1.1 // indirect
|
|
github.com/golang-jwt/jwt/v5 v5.3.0 // indirect
|
|
github.com/golang/snappy v0.0.4 // indirect
|
|
github.com/klauspost/compress v1.18.0 // indirect
|
|
github.com/kr/text v0.2.0 // indirect
|
|
github.com/montanaflynn/stats v0.7.1 // indirect
|
|
github.com/pmezard/go-difflib v1.0.0 // indirect
|
|
github.com/rogpeppe/go-internal v1.11.0 // indirect
|
|
github.com/stretchr/objx v0.5.2 // indirect
|
|
github.com/xdg-go/pbkdf2 v1.0.0 // indirect
|
|
github.com/xdg-go/scram v1.1.2 // indirect
|
|
github.com/xdg-go/stringprep v1.0.4 // indirect
|
|
github.com/youmark/pkcs8 v0.0.0-20240726163527-a2c0da244d78 // indirect
|
|
golang.org/x/crypto v0.41.0 // indirect
|
|
golang.org/x/sync v0.16.0 // indirect
|
|
golang.org/x/text v0.28.0 // indirect
|
|
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect
|
|
gopkg.in/yaml.v3 v3.0.1 // indirect
|
|
)
|