Skip to content

Commit bf2b6ba

Browse files
committed
Send json content-type to Jenkins
1 parent b002f52 commit bf2b6ba

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lambdawebhook/hook.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,12 @@ def lambda_handler(event, context):
2424
if verified:
2525
response = requests.post(event['jenkins_url'],
2626
headers={
27+
'Content-Type': 'application/json',
2728
'X-GitHub-Delivery': event['x_github_delivery'],
2829
'X-GitHub-Event': event['x_github_event'],
2930
'X-Hub-Signature': event['x_hub_signature']
3031
},
31-
json=event['payload'])
32+
data=event['payload'])
3233
response.raise_for_status()
3334
else:
3435
raise requests.HTTPError('400 Client Error: Bad Request')

0 commit comments

Comments
 (0)