Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Trello API webhook stopped working

Could you help me with the Trello API, please?

For more than year i've been using the api with a webhook to notify .php file when a card is moved to another list, but recently i noticed that all the webhooks are not working any more. I haven't changed anything on my .php file and i was wondering if something on the API site has changed?

The .php file basically sends an email when a card is moved to a certain list. I use a webhook to notify the php file for the event. 

I don't know how to check for errors and o see where is the problem. If you can help I'll be soo much thankful...

2 answers

1 accepted

1 vote
Answer accepted

Solved! 

So the request are made from:
107.23.104.115 - - [17/Jan/2019:14:57:18 +0200] "POST /trello.php HTTP/1.1" 403 219 "-" "-"
54.152.166.250 - - [17/Jan/2019:14:57:47 +0200] "POST /trello.php HTTP/1.1" 403 219 "-" "-"

And it appeared that in .htaccess there was Deny rule for those IP addresses. Removed it and everything is back to normal. 

1 vote
Iain Dooley Community Leader Jan 16, 2019

@Tsvetan Tsakov if you look in your Trello settings, does that API token still have access to your account?

If so you should be able to fetch a list of all your webhooks valid for that token:

https://developers.trello.com/reference/#tokenstokenwebhooks

If the webhooks exist, what I would recommend is checking that the posts are making it to your server.

If they're not possible problems may be to do with either DNS or SSL, have you confirmed that the same URL you're using with Trello's webhooks are working in other situations for example in your web browser or as a webhook with another service such as Zapier?

Hi @Iain Dooley thank you for your advises! 

In my Trello settings, the token looks okay:

token.JPG
and here https://developers.trello.com/reference/#tokenstokenwebhooks it lists correctly all the webhooks with status code 200. I tried zapier - it was okay.

However when i try to create a new webhook it returns 400 Bad Request:

URL (https://www.advokatami.bg/trello.php) did not return 200 status code, got 403

RESPONSE HEADERS

access-control-allow-headers: Authorization, Accept, Content-Type
access-control-allow-methods: GET, PUT, POST, DELETE
access-control-allow-origin: *
cache-control: max-age=0, must-revalidate, no-cache, no-store
connection: keep-alive
content-length: 82
content-type: text/plain; charset=utf-8
date: Thu, 17 Jan 2019 09:41:22 GMT
etag: W/"52-YG0G//vf2zebqZ4zFwgJOnQCGQs"
expires: Thu, 01 Jan 1970 00:00:00
pragma: no-cache
referrer-policy: strict-origin-when-cross-origin
strict-transport-security: max-age=15552000
surrogate-control: no-store
vary: Accept-Encoding
x-content-type-options: nosniff
x-dns-prefetch-control: off
x-download-options: noopen
x-frame-options: DENY
x-trello-environment: Production
x-trello-version: 1.1512.0
x-xss-protection: 1; mode=block

When i check the url here: https://httpstatus.io/ it is status 200.
The beginning of my php file is:

$data = json_decode(file_get_contents("php://input"), true);
$cardName = $data['action']['data']['card']['name'];
$contact = explode(",", $cardName);
$firma = $contact[0];
$receivedListID = $data['action']['data']['listAfter']['id'];


 

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Trello

📹 What is Trello?

Hello Community!  My name is Brittany Joiner and I am a Trello enthusiast and Atlassian Community Leader. I'll be sharing with you a series of videos with my top tips on how to best use Trello...

330 views 10 22
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you