Cors Error when calling Apis from browser

42 views
Skip to first unread message

arslan...@gmail.com

unread,
Apr 3, 2020, 2:18:51 AM4/3/20
to Assembla API Development
Hi, i am new here, so apologizing in case of any blunder 

My Question is : i have trying to call assembla apis in order to perform certain tasks like ticket creation from my browser. But when i try to call api from postman it works like charm but when i do the same from browser i get
Error: " ... has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource."

Here is my code
 axios.post("https://api.assembla.com/v1/spaces/"+spaceId+"/tickets.json"
        {"ticket":{"summary":"Testssss"}}
        , {
            headers: {
                'Content-Type':'application/json',
                "X-Api-Key": key,
                "X-Api-Secret": secretKey,
                'Access-Control-Allow-Origin':"*" ( same issue with or without this)
                
            }
        })

Thank you in advance.

Stanislav Kolotinskiy

unread,
Apr 3, 2020, 8:13:25 AM4/3/20
to arslan...@gmail.com, Assembla API Development
Hi,

we don’t support CORS requests to our API right now, but we will put that into our list of feature requests. I can’t provide any ETA, but will let you know of any updates to this subject. Thank you and have a nice day!

Regards,
Stanislav

--
You received this message because you are subscribed to the Google Groups "Assembla API Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to assembla-api-d...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/assembla-api-dev/17be9a97-e141-42b2-a482-62130b676405%40googlegroups.com.

Reply all
Reply to author
Forward
0 new messages