Toggle Side Panel

  • Blogs
  • Consultants
    • Salesforce Product Expertise
      • Top Salesforce ConsultantsTop Salesforce Consultants
      • Marketing Cloud ConsultantsMarketing Cloud Consultants
      • Service Cloud ConsultantsService Cloud Consultants
      • Experience Cloud ConsultantsExperience Cloud Consultants
      • Analytics Cloud ConsultantsAnalytics Cloud Consultants
    • Salesforce Industry Expertise
      • Non-Profit Cloud ConsultantsNon-Profit Cloud Consultants
      • Financial Service Cloud ConsultantsFinancial Service Cloud Consultants
      • Health Cloud ConsultantsHealth Cloud Consultants
      • Commerce Cloud ConsultantsCommerce Cloud Consultants
      • Manufacturing Cloud ConsultantsManufacturing Cloud Consultants
    • Salesforce Experts by Location
      • USATop Salesforce Consultants in USA
      • IndiaTop Salesforce Consultants in India
      • AustraliaTop Salesforce Consultants in Australia
      • United KingdomTop Salesforce Consultants in UK
      • CanadaTop Salesforce Consultants in Canada
  • Webinars
  • Contact Us
  • Discussions
More options
    Sign in Sign up
    • Blogs
    • Consultants
      • Salesforce Product Expertise
        • Top Salesforce ConsultantsTop Salesforce Consultants
        • Marketing Cloud ConsultantsMarketing Cloud Consultants
        • Service Cloud ConsultantsService Cloud Consultants
        • Experience Cloud ConsultantsExperience Cloud Consultants
        • Analytics Cloud ConsultantsAnalytics Cloud Consultants
      • Salesforce Industry Expertise
        • Non-Profit Cloud ConsultantsNon-Profit Cloud Consultants
        • Financial Service Cloud ConsultantsFinancial Service Cloud Consultants
        • Health Cloud ConsultantsHealth Cloud Consultants
        • Commerce Cloud ConsultantsCommerce Cloud Consultants
        • Manufacturing Cloud ConsultantsManufacturing Cloud Consultants
      • Salesforce Experts by Location
        • USATop Salesforce Consultants in USA
        • IndiaTop Salesforce Consultants in India
        • AustraliaTop Salesforce Consultants in Australia
        • United KingdomTop Salesforce Consultants in UK
        • CanadaTop Salesforce Consultants in Canada
    • Webinars
    • Contact Us
    • Discussions
    Close search

    Activity › Forums › Salesforce® Discussions › What to do in case I am getting Rest API error?

    Tagged: Access Token, Debug in Salesforce, Get and set Methods, HTTP GET, HTTP POST, HTTP Request, JSON Deserialization, Login URL, Old Version, Rest API, REST API Error, Salesforce Apps, Salesforce Code, Salesforce Error

    • Salesforce® Discussions

      What to do in case I am getting Rest API error?

      Posted by Rahul on January 30, 2018 at 8:33 AM

      HI,
      I updated my http request code but now I am getting an error "You are running an old version of the app. Please upgrade to the latest version".
      here is my code of calling access token:-

      public string getAccessTokenNew(){
      String strEndpointUrl='';
      HttpRequest tokenRequest = new HttpRequest();
      if(objZoomtechConfig !=null){
      strEndpointUrl = objZoomtechConfig.RV_Login_URL__c;
      tokenRequest.setBody('grant_type=password&client_id=zoom-dev1-client&session_reset=no&username='+objZoomtechConfig.RV_Username__c + '&password='+ objZoomtechConfig.RV_Password__c);
      }
      //Creating Http request object

      tokenRequest.setendpoint(strEndpointUrl);
      tokenRequest.setHeader('Content-Type', 'application/x-www-form-urlencoded');
      tokenRequest.setmethod('POST');
      Http objHttp = new Http();
      HttpResponse res = objHttp.send(tokenRequest);  // here response is [Status=OK, StatusCode=200]
      system.debug('@@'+res.getBody()); // but here i am getting this  DEBUG |@@ {"response":null,"status":"FAILURE","errorMessage":"You are running an old version of the app. Please upgrade to the latest version."}
      objResponse = (responseClass)JSON.deserialize( res.getBody(),responseClass.Class);

      if(objResponse.response != NULL){
      strAccessToken = objResponse.response.access_token;
      system.debug('@@@'+strAccessToken);
      objZoomtechConfig.Access_Token__c = objResponse.response.access_token;
      objZoomtechConfig.Expires_In__c= Decimal.valueOf(objResponse.response.expires_in);
      objZoomtechConfig.Token_Generation_Time__c = System.now();
      update objZoomtechConfig;
      }

      Please guide me, why i am getting this issue?

      thanks,
      Rahul Kumar

      Rahul replied 8 years, 7 months ago 2 Members · 2 Replies
      • Access Token
      • Debug in Salesforce
      • Get and set Methods
      • HTTP GET
      • HTTP POST
      • HTTP Request
      • JSON Deserialization
      • Login URL
      • Old Version
      • Rest API
      • REST API Error
      • Salesforce Apps
      • Salesforce Code
      • Salesforce Error
    • 2 Replies
    • Manpreet

      Member
      January 30, 2018 at 10:32 AM

      Hi Rahul,

      API version is defined in different different ways depending on what you are doing with it.

      SOAP API calls
      REST API calls
      Apex
      Visualforce
      All of these (and other features that use API) are fixed in the code you write against them, allowing you to upgrade/update when it fits your company/project lifecycle. Integration uses different end points. Apex and Visualforce use metadata to define the version.

      Essentially there is only ever one version of Salesforce in production. Previous versions of the API are emulated for the purpose of integration and code resilience.

      So when you write your REST request (as that's what you've been using), you will use a URL like this, for instance:

      HTTP:GET
      /services/data/v26.0/sobjects/account/001B0000003nJhxxxx

      The v26.0 segment of the URL path is what stipulates the version. You can substitute any other previous or later version up to the current version (v33.0 for Spring 15, the current release).

      n some instances you will get a response, but a different result. For instance these two GETendpoints:

      /services/data/v26.0/sobjects/account/001B0000003nJhJIAU
      /services/data/v33.0/sobjects/account/001B0000003nJhJIAU

      The second returns a few extra fields that were added in the ensuing versions.So manage your strEndpointUrl in the code.

       

      Thanks.

    • [adinserter block='9']
    • Rahul

      Member
      January 31, 2018 at 5:28 AM

      Thanks for reply manpreet, but i am not calling such endpoint so i am not getting your point.
      I am just calling two api's , in first i am generating the access_token and then uudating this new access token in custom setting. and next to using second api which will take data from sfdc to java applicaion.
      now in first case, as i am calling the httpRequest then status is 200Ok but getting this error message

      error "You are running an old version of the app. Please upgrade to the latest version" which is working fine in sandbox.
      how to fetch this fault, it's important to me to solve ASAP.
      Someone please guide me soon!

      Thanks,

      Rahul Kumar

    Log In to reply.

    • Public
    • All Members
    • My Connections
    • Only Me
    • Public
    • All Members
    • My Connections
    • Only Me
    • Public
    • All Members
    • My Connections
    • Only Me

    Popular Salesforce Blogs

    Engage Users and Associates in Real-time, Visual and Voice Cues With Salesforce Service Cloud

    Blog in Salesforce, Salesforce Cloud Platform

    Eliminate physical contact with customers without compromising important face time. You can use Visual Remote Assistant to provide emergency assistance via video call. As a…

    Bandwidth, Call Routing, Case Resolution, Chatbots, Client
    Apphienz Jan 7, 2022
    3,226  Views

    Outsourced Salesforce Administration Services

    Blog in Salesforce Admin

    In the dynamic landscape of modern business, managing a robust Salesforce system is essential to drive growth and streamline operations. However, the complexities of Salesforce…

    Australia, Benefits, Best Practices, Business Goals, Certified Experts
    Kizzy Consulting Oct 23, 2023
    1,383  Views

    Difference between a Salesforce Administrator and a Salesforce Developer

    Blog in Others

    Managing your business, you will definitely meet a question how to store and analyze data about your customers and their needs. Times when you did…

    Apex Triggers, api-integration, Application Development, Configuration, Connection
    Vimera | Andersen Mar 28, 2024
    989  Views

    Popular Salesforce Videos

    Customize Salesforce Lightning Home page

    Customize Salesforce Lightning Home page

    Video in Lightning

    In this video Signiforce shows : How to customize the Salesforce Lightning Home page. Update an existing Salesforce lightning home page or create a new…

    Salesforce Training, Salesforce Tutorial, Salesforce Lightning, salesforce, Lightning Components
    Mayra Dec 20, 2022
    1,705  Views
    Why To Sell Your SAAS Application On Salesforce AppExchange ?

    Why To Sell Your SAAS Application On Salesforce AppExchange ?

    Video in Others

    From unparalleled market reach to seamless integration and trusted security, explore the benefits that await SAAS entrepreneurs on Salesforce AppExchange. Watch our latest webinar to…

    Salesforce Developer, Salesforce Integration, salesforce platform, Customer Success, Salesforce Hulk
    Cyntexa Jul 14, 2023
    979  Views
    Salesforce Consumer Goods Cloud Demo

    Salesforce Consumer Goods Cloud Demo

    Video in Others, Salesforce Stories

    Salesforce Consumer Goods Cloud is an intelligent, seamless B2B CRM solution specifically designed for the consumer goods industry. Watch this video to learn more.

    Salesforce Training, salesforce, Salesforce Video, Salesforce Learning, B2B
    Abhishek Dec 24, 2020
    2,395  Views
    Footer Forcetalks logo

    support@forcetalks.com

    • twitterx

    Quick Links

    Advertise with Us

    Salesforce® Articles

    Dreamforce 2023

    Top Salesforce® Bloggers 2023

    Top Salesforce Consultants

    Get Listed

    Company

    Contact Us

    About Us

    Privacy Policy

    Terms & Conditions

    InsightHub

    Salesforce Blogs

    Salesforce Videos

    Salesforce Groups

    Salesforce Jobs

    © 2026 - Forcetalks ● All Rights Reserved

    Salesforce® is a trademark of Salesforce® Inc. No claim is made to the exclusive right to use “Salesforce”. Any services offered within the Forcetalks website/app are not sponsored or endorsed by Salesforce®.

    We use cookies to enhance your browsing experience. Please see our privacy policy if you'd like more information on our use of cookies.