API v1 submission error

Hi, I’m trying to send data submit into a form but it got a error:

curl -X POST   https://kc.domain.tld/api/v1/submissions  -u user:secret  -H 'Content-Type:application/json'   -d '{ "id": "69", "submission":  { "url": "test", "category":"1"}}'

{"error":"Improperly formatted XML."}

I don’t find documentation about it.

Thanks for your help.

Hrmmm. I think this is the documentation you need, but at first glance I’m not sure what’s wrong with the post you’re making: https://kc.kobotoolbox.org/api/v1/submissions.

If you navigate to that URL via browser, are you able to successfully make a post using the API testing/documentation UI?

Taylor

2 Likes

Hi @finlay,

Would you mind having a look at this post:

It should provide you some help.

Have a great day!

1 Like

Thank you, but doesn’t work v1 API, now I’m trying with v2 API without luck.

Thanks for your reply, for now I’m trying with API v2 but I still doesn’t found a complete documentation and I’m trying and failing.