Skip to main content
Published: August 31 2016, 10:12:00 PMUpdated: November 28 2020, 4:17:31 PM

I am using the .NET SDK to make a call to GetSessionID and I get the following error:

<DetailedMessage>Invalid user name or password. The username/password pair specified for the user is not valid. You may not use an email address as a username if the member has a User ID.</DetailedMessage>

Why am I getting this error?

Detailed Description

This issue happens only in SDK versions earlier than 595. 

For most of the calls a user token is expected.  However, in the case of GetSessionID, you do not send any user token, since the call itself is used to help get a token.  Since there no token, it sends in an empty UserID and Password field, which causes the error.

If you look at the log file, this is what it sends:

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap=""xmlns:xsi=""xmlns:xsd="">
  <RequesterCredentials xmlns="urn:ebay:apis:eBLBaseComponents">
  <GetSessionIDRequest xmlns="urn:ebay:apis:eBLBaseComponents">

To resolve this issue, you need to explicitly set the eBayAccount property to null as below:

context.ApiCredential.eBayAccount = null; 

context.ApiCredential.eBayAccount = Nothing 

Additional Info    

API Documentation: Authentication & Authorization  

How well did this answer your question?
Answers others found helpful