2

I'm building a browser based application in Javascript. I've tried to access the docusign api via jQuery:

$.support.cors = true;
$.ajax({crossDomain:true, url:"https://demo.docusign.net/restapi/v2"})

I get the error:

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://demo.docusign.net/restapi/v2?_=1407189114238. This can be fixed by moving the resource to the same domain or enabling CORS.

Accessing other APIs such as yahoo, totally works:

$.ajax({crossDomain:true, url:"https://query.yahooapis.com/v1/public/yql"})

Is there a special thing that I need to do for docusign api? Thanks. (Note: My examples here use blank queries to illustrate whether an api is accessible at all. The actual code uses real queries. This problem is not caused by not having a real query. You can see this yourself by pasting the above url into your browser and see that it returns some xml.)

4
  • 2
    Can you please show what you've tried (paste code) and error messages? Commented Aug 4, 2014 at 17:45
  • Ok. Updated with real code. Commented Aug 4, 2014 at 22:00
  • That isn't a valid DocuSign request, also you're going to have to pass headers some how. It appears this is a duplicate question of stackoverflow.com/questions/21987824/… Commented Aug 5, 2014 at 3:01
  • DocuSign does not support CORS, which is why you are getting the error "Cross-Origin Request Blocked". As Andrew mentioned you're request is invalid (you're not hitting a valid URL with "demo.docusign.net/restapi/v2") however even if you were you can't use CORS with the DocuSign API. Commented Aug 5, 2014 at 17:39

1 Answer 1

4

DocuSign does not support CORS (Cross-Origin Resource Sharing) in its platform. There are too many potential security risks with CORS and for DocuSign to maintain its extremely high level of security and certification compliance it can not support CORS.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.