MCPcopy Index your code
hub / github.com/google/go-github / Subscribe

Method Subscribe

github/repos_hooks.go:230–237  ·  view source on GitHub ↗

Subscribe lets servers register to receive updates when a topic is updated. GitHub API docs: https://docs.github.com/webhooks/about-webhooks-for-repositories#pubsubhubbub meta:operation POST /hub

(ctx context.Context, owner, repo, event, callback string, secret []byte)

Source from the content-addressed store, hash-verified

228//
229//meta:operation POST /hub
230func (s *RepositoriesService) Subscribe(ctx context.Context, owner, repo, event, callback string, secret []byte) (*Response, error) {
231 req, err := s.createWebSubRequest(ctx, "subscribe", owner, repo, event, callback, secret)
232 if err != nil {
233 return nil, err
234 }
235
236 return s.client.Do(req, nil)
237}
238
239// Unsubscribe lets servers unregister to no longer receive updates when a topic is updated.
240//

Callers 1

Calls 2

createWebSubRequestMethod · 0.95
DoMethod · 0.45

Tested by 1