cors error

28 views
Skip to first unread message

Dave Ford

unread,
Apr 28, 2017, 12:54:52 PM4/28/17
to checkvist-api
I am getting this error:

Fetch API cannot load https://checkvist.com/checklists/610976/tasks.json. No 'Access-Control-Allow-Origin' header is present on the requested resource.

Is it possible to call this api directly from a browser?

Thanks.

KIR

unread,
Apr 28, 2017, 12:58:10 PM4/28/17
to checkv...@googlegroups.com
Hello Dave,

   Right now, CORS is not enabled for https://checkvist.com, but you can try using it on https://beta.checkvist.com. The API is expected to work only when token-based authentication is used.

   Kind regards,
   KIR


--
You received this message because you are subscribed to the Google Groups "checkvist-api" group.
To unsubscribe from this group and stop receiving emails from it, send an email to checkvist-api+unsubscribe@googlegroups.com.
To post to this group, send email to checkv...@googlegroups.com.
Visit this group at https://groups.google.com/group/checkvist-api.
For more options, visit https://groups.google.com/d/optout.



--
Kirill (KIR) Maximov
Software Engineer & Starter

Twitter:       https://twitter.com/maxkir
https://checkvist.com

Dave Ford

unread,
Jun 16, 2017, 4:43:45 PM6/16/17
to checkvist-api, k...@checkvist.com
Thanks for your reply. I am still getting this error:

"Fetch API cannot load https://beta.checkvist.com/checklists/620525/tasks.json?with_notes=true. Request header field authorization is not allowed by Access-Control-Allow-Headers in preflight response."

Here is my request:

const headers = new Headers()
const auth = "Basic " + btoa(
email + ":" + authToken)
console.log("auth: ", auth)
headers.append('Authorization', auth)
return fetch(url, {method: "GET", headers: headers})

On Friday, April 28, 2017 at 9:58:10 AM UTC-7, KIR wrote:
Hello Dave,

   Right now, CORS is not enabled for https://checkvist.com, but you can try using it on https://beta.checkvist.com. The API is expected to work only when token-based authentication is used.

   Kind regards,
   KIR

On 26 April 2017 at 02:03, Dave Ford <df...@smart-soft.com> wrote:
I am getting this error:

Fetch API cannot load https://checkvist.com/checklists/610976/tasks.json. No 'Access-Control-Allow-Origin' header is present on the requested resource.

Is it possible to call this api directly from a browser?

Thanks.

--
You received this message because you are subscribed to the Google Groups "checkvist-api" group.
To unsubscribe from this group and stop receiving emails from it, send an email to checkvist-ap...@googlegroups.com.

To post to this group, send email to checkv...@googlegroups.com.
Visit this group at https://groups.google.com/group/checkvist-api.
For more options, visit https://groups.google.com/d/optout.

KIR

unread,
Jun 16, 2017, 4:56:38 PM6/16/17
to checkv...@googlegroups.com
Hello Dave,

  Unfortunately, CORS in Checkvist requires token authorisation as I mentioned in the previous e-mail. Basic authentication won't work. You should run /auth/login.json request first to obtain a token, and use this token as a parameter for further requests.

  Hope this helps,
  KIR


To unsubscribe from this group and stop receiving emails from it, send an email to checkvist-api+unsubscribe@googlegroups.com.

To post to this group, send email to checkv...@googlegroups.com.
Visit this group at https://groups.google.com/group/checkvist-api.
For more options, visit https://groups.google.com/d/optout.

Dave Ford

unread,
Jun 16, 2017, 5:16:22 PM6/16/17
to checkv...@googlegroups.com
What is the parameter called?

--
You received this message because you are subscribed to a topic in the Google Groups "checkvist-api" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/checkvist-api/N6rT4HCGkYA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to checkvist-api+unsubscribe@googlegroups.com.

To post to this group, send email to checkv...@googlegroups.com.
Visit this group at https://groups.google.com/group/checkvist-api.
For more options, visit https://groups.google.com/d/optout.

KIR

unread,
Jun 17, 2017, 10:14:34 AM6/17/17
to checkv...@googlegroups.com
Hello Dave,

   The name of the parameter is token, as described at https://checkvist.com/auth/api. The token has a limited lifetime and should be refreshed when expired, see details in the authentication section of the docs.

  Hope this helps,
  KIR

Reply all
Reply to author
Forward
0 new messages