I am trying to create a task via curl and it is coming back with the rejection of “unrecognized workspace”, and following the ASANA manual also from error.
I was wondering if you could explain me step by step to create a task via curl please.
Many thanks for the return Frederic_Malenfant
but in the example you gave me, it’s with JSON file, and the test we’re doing doesn’t use this file, it’s directly from cURL.
Example of how I accessed my account:
curl -H “Authorization: Bearer x / xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx” https://app.asana.com/api/1.0/users/me
Now I would like to know how to create a task directly by cURL without the JSON file please.
No, it’s with json “string” on the command-line using curl. You must use json syntax to send “post” data to asana, but curl allow sending json data by configuring the header “content-type”, then use the -data paramater with your valid json string after. You don’t need a “file”.