Task update API

Hi!

I'm working on an integration with a NodeJS ms. I'd like to update the description but I'm bit confused.

Following the docs, I read that all the params are URL Params. This lead all the request to fail, status 400, with the server answering that parameter 'description' is not allowed.

So, I made a request that match the CURL example given in the docs.

I got 200 with every kind of body submitted but I saw that nothing has changed in the response body. 

So, how to properly consume this API?

0
👍 Spot On 💡 Innovative Approach 💪 Stellar Advice ✅ Solved 🪄 Remove Kudos
4件のコメント

Valerio Como maybe you could paste your CURL request here (without the token) to see if we could spot any issue with it?

Usually, the issue might be missing or wrong url encoding.

 

You could also try to use the new web-base swagger style api page to test out your request:

https://developers.wrike.com/apiv4-schema-reference/#operations-tag-Tasks

and see if it works on the web page itself and then you could compare the generated CURL with yours.

 

 

1
👍 Spot On 💡 Innovative Approach 💪 Stellar Advice ✅ Solved 🪄 Remove Kudos

this is my first test

curl --location --request PUT 'app-eu.wrike.com/api/v4/tasks/IEAEPV5EKRSWT5WH?description=hi' \
--header 'Authorization: ••••••' \
 
I got a 400 with this response payload
 
{
"errorDescription":"Parameter 'description' is not allowed",
"error":"invalid_request"
}
 
So, I did a second test. I tried sending a body, like most PUT does.
 
curl --location --request PUT 'app-eu.wrike.com/api/v4/tasks/IEAEPV5EKRSWT5WH' \
--header 'Content-Type: text/plain' \
--header 'Authorization: ••••••' \
--data 'description=hi'
 
and a third test
 
curl --location --request PUT 'app-eu.wrike.com/api/v4/tasks/IEAEPV5EKRSWT5WH' \
--header 'Content-Type: application/json' \
--header 'Authorization: ••••••' \
--data '{ "description": "hi"}'
 
In both cases I got 200 but nothing is changed in my task.
What's wrong? What's the right way to consume this API?
 
 
0
👍 Spot On 💡 Innovative Approach 💪 Stellar Advice ✅ Solved 🪄 Remove Kudos

Hi Valerio Como, I've asked our Support API specialists to reach out to you to help 👍

Lisa Community Team at Wrike Wrike Product Manager Wrike DiscoverでWrikeの専門家になりましょう

Lisa Wrike Team member Wrike DiscoverでWrikeの専門家になりましょう

0
👍 Spot On 💡 Innovative Approach 💪 Stellar Advice ✅ Solved 🪄 Remove Kudos

Thank you Lisa

0
👍 Spot On 💡 Innovative Approach 💪 Stellar Advice ✅ Solved 🪄 Remove Kudos

Folllowing List for Post: Task update API
[this list is visible for admins and agents only]

トップ

今後のライブセッション

お探しのものが見つかりませんか? 新しい投稿を作成する