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)
| 228 | // |
| 229 | //meta:operation POST /hub |
| 230 | func (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 | // |