Skip to content

Instantly share code, notes, and snippets.

@andrewgross
Created August 13, 2015 20:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andrewgross/c0f80a4033f30a287e47 to your computer and use it in GitHub Desktop.
Save andrewgross/c0f80a4033f30a287e47 to your computer and use it in GitHub Desktop.
headers = {
"Accept": "application/vnd.travis-ci.2+json"
"Authorization": "token {}".format(travis_token)
}
hook_data = {
"hook": {
"id": hook_id,
"active": True,
}
}
enable_hooks_response = requests.put("{}/hooks".format(TRAVIS_ENDPOINT), headers=headers, data=hook_data)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment