Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3794080
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T12:52:29+00:00 2026-05-19T12:52:29+00:00

I am calling the REST API service of Vimeo using the following code snippet,

  • 0

I am calling the REST API service of Vimeo using the following code snippet, the data comes out as null with a 200 OK call.

    $.ajax({
        url:'http://vimeo.com/api/rest/v2?format=json&method=vimeo.videos.getInfo&video_id=7100569',
        dataType:'json',
        success:function(data){
            alert(data);
        }
    });

When I copy paste the url (http://vimeo.com/api/rest/v2?format=json&method=vimeo.videos.getInfo&video_id=7100569) in the browser it gives me a file to download.
I checked out the sample javascript examples which do work

var url='http://vimeo.com/api/rest/v2?format=json&method=vimeo.videos.getInfo&video_id=7100569';
        var js = document.createElement('script');
        js.setAttribute('type', 'text/javascript');
        js.setAttribute('src', url);
        document.getElementsByTagName('head').item(0).appendChild(js);

I just wanted to know what am I doing wrong here. Note the second snippet gives a valid JSON error instead of null response.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T12:52:30+00:00Added an answer on May 19, 2026 at 12:52 pm

    After look at it several times (and posting then deleting my comment), this is what I came up with:

    The fact that you are getting a “file” is just a function of how the browser is treating the result. Chrome displayed the result just fine while IE tried to save it off to a file.

    You are having an issue because you can’t do AJAX requests to a domain that is different than the one the page originated from. This is what David Dorward was getting at. The example they provide is jsonp (which is different than json). Essentially, you should be able to change the dataType in your ajax call to ‘jsonp’, and hopefully it will start working for you.

    HTH

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am calling Assembla REST Api with basic authentication using the following code. I
I am succesfully calling a REST API with the following code $client = new
I am calling an external REST service (Vimeo REST API). The response of the
I am very new with Java. I am using following code for the calling
The following function works perfectly on our production site function flickrGetPhotos(){ $.getJSON(http://api.flickr.com/services/rest/?method=flickr.photosets.getList&api_key= + flickrApiKey
I'm using the old Rest API (and old Javascript SDK) to develop an iframe
I am calling a rest webscript using Extjs with JSON,but unable to display on
I'm using Hammock in a Windows Phone app to request data from a REST
I have a Jersey client that is successfully calling a REST service and populating
I'm having trouble with not getting connections when calling a rest api with com.sun.jersey.client.apache.ApacheHttpClient

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.