function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Ajay LAjay L 

Failed to login: UNSUPPORTED_API_VERSION - Invalid Api version specified on URL

Hi,

I am trying to deploy/retrieve/validate the metadata with Ant scripts to sandbox environment and it gives me the below error:

Error: Failed to login: UNSUPPORTED_API_VERSION - Invalid Api version specified on URL

Sandbox API version: 36.0

CustomPackage.xml API version: 36.0 (I did tried with 35 also)
It is working with another sandbox with APT version 37.0

Can you please help me how to solve this issue?
User-added image
Regards,
Ajay
 
Best Answer chosen by Ajay L
Ajay LAjay L
I could resolve replacing ant migration with v36 in my local ant folder.

Rgards,
Ajay

All Answers

@Karanraj@Karanraj
Looks like there might be miss match between your sandbox API version and migration tool version. You have to try with the older version migration tool. Check this thread for similar issue - http://salesforce.stackexchange.com/questions/66309/failed-to-login-unsupported-api-version-invalid-api-version-specified-on-url
Ajay LAjay L
Karanrajs, Thanks for your reply.
Do you mean to say that, I should download migration toll v35.0 since my sandbox is v.36.0?
@Karanraj@Karanraj
It's has to be version 36 or below Thanks, Karan
Ajay LAjay L
the one I had downloaded is from the same sandbox. v36.0. Still I have the issue for some reason.
Ajay LAjay L
Anyone please help me out here.

I still has this issue unresolved.

I am only having this issue with v36.0 sandboxed for some reason.

Regards,
Ajay
Ajay LAjay L
I could resolve replacing ant migration with v36 in my local ant folder.

Rgards,
Ajay
This was selected as the best answer
sandeep@Salesforcesandeep@Salesforce
Hi Ajay, 

I faced same issue and resolved it by downloading similar version ( what my org was having) of ant-salesforce jar file and put that in to lib folder of apache ant folder. 

Here is the below URL you may download 

Note: Here you may put any version number in place of 'nn' in below URL as per your org you are working with 

https://gs0.salesforce.com/dwnld/SfdcAnt/salesforce_ant_nn.0.zip

for example for for 36.0 
https://gs0.salesforce.com/dwnld/SfdcAnt/salesforce_ant_nn.0.zip

Thanks
Sandeep Singhal
http://www.codespokes.com/