You need to sign in to do that
Don't have an account?

Meta data API throws INVALID_SESSION_ID
I used SF Metadata API(18.0) to check whether a page exist in a given account using existing sessions.
I used existing session ID to connect SF through Metadata API.
I have two SF accounts for test purposes. Both accounts have session expiry over 2 hours.
But Metadata API does not work for one of the two accounts.
(Further I see both the accounts work fine with the SF web service API)
I used existing session ID to connect SF through Metadata API.
I have two SF accounts for test purposes. Both accounts have session expiry over 2 hours.
But Metadata API does not work for one of the two accounts.
(Further I see both the accounts work fine with the SF web service API)
Could anyone please point out why Metadata API successful only in one account? Please see the below error trace:
AxisFault
faultCode: {http://soap.sforce.com/2006/04/metadata}INVALID_SESSION_ID
at org.apache.axis.message.SOAPFaultBuilder.createFault(SOAPFaultBuilder.java:222)
faultSubcode:
at org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:129)
at org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:1087)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:601)
faultString: INVALID_SESSION_ID: Invalid Session ID found in SessionHeader: Illegal Session. Session not found, missing session key:
faultCode: {http://soap.sforce.com/2006/04/metadata}INVALID_SESSION_ID
at org.apache.axis.message.SOAPFaultBuilder.createFault(SOAPFaultBuilder.java:222)
faultSubcode:
at org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:129)
at org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:1087)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:601)
faultString: INVALID_SESSION_ID: Invalid Session ID found in SessionHeader: Illegal Session. Session not found, missing session key: