Was this helpful?
Login Resource
Description
Log in and start a session. The provided username and password combination is authenticated against the Actian DataCloud membership service and a session ID is returned. This session ID is to be used in all subsequent REST calls, either in the form of a sessionid cookie or as query parameters.
You can access the login resource using either POST or GET.
POST Method
When you log in using the POST method, send the username and password in the body of your request.
URL
https://datacloud2.pervasive.com/EntityAPIService/REST/login
The following response types are available via the optional Accept header in your request:
application/xml (default)
application/json
text/xml
Example
Request
POST https://datacloud2.pervasive.com/EntityAPIService/REST/login HTTP/1.1
Host: datacloud2.pervasive.com
Body
username=testuser&password=mypass
Response
Header
HTTP/1.1 200 OK
Date: Tue, 05 Apr 2011 05:15:23 GMT
Server: Sun GlassFish Enterprise Server v2.1.1
X-Powered-By: Servlet/2.5
Content-Type: application/xml
Content-Length: 256
Set-Cookie: sessionid=125003110405.7959.32B6.31A6.4276.97E8.C404;Version=1
Connection: close
application/xml
<LoginResult>
   <message>Login was successful.</message>
   <sessionId>49bfe32d-df30-4797-a8b1-96da5c1b5609</sessionId>
   <success>true</success>
   <visitorKey>11042EB6A3DFE1A34B25</visitorKey>
</LoginResult>
application/json
{
 "message": " Login was successful.",
 "sessionId": "49bfe32d.df30.4797.a8b1.96da5c1b5609",
 "success": "true",
 "visitorKey": "11043AE84FD9155C4CD3"
}
text/xml
<LoginResult>
   <message>Login was successful.</message>
   <sessionId>49bfe32d.df30.4797.a8b1.96da5c1b5609</sessionId>
   <success>true</success>
   <visitorKey>1104B8419AE311204C07</visitorKey>
</LoginResult>
GET Method
When you log in using the GET method, the username and password are query parameters for your request.
URL
https://datacloud2.pervasive.com/EntityAPIService/REST/login?username={username}&password={password}
The following response types are available via the optional Accept header in your request:
application/xml (default)
application/json
text/xml
Parameters
 
Name
Type
Description
Required?
username
String
User name of the DataCloud user.
Yes.
password
String
Password of the DataCloud user.
Yes.
Example
Request
GET https://datacloud2.pervasive.com/EntityAPIService/REST/login?username=testuser&password=mypass HTTP/1.1
Host: datacloud2.pervasive.com
Response
Header
HTTP/1.1 200 OK
Date: Tue, 05 Apr 2011 05:17:00 GMT
Server: Sun GlassFish Enterprise Server v2.1.1
X-Powered-By: Servlet/2.5
Content-Type: application/xml
Content-Length: 256
Set-Cookie: sessionid=125003110405.8F55.78CE.7C90.4684.9A5B.3830;Version=1
Connection: close
application/xml
<LoginResult>
   <message>Login was successful.</message>
   <sessionId>49bfe32d-df30-4797-a8b1-96da5c1b5609</sessionId>
   <success>true</success>
   <visitorKey>1104B119CECE99F84359</visitorKey>
</LoginResult>
application/json
{
 "message": " Login was successful.",
 "sessionId": "49bfe32d-df30-4797-a8b1-96da5c1b5609",
 "success": "true",
 "visitorKey": "110462F0545B404D4F1E"
}
text/xml
<LoginResult>
   <message>Login was successful.</message>
   <sessionId>49bfe32d-df30-4797-a8b1-96da5c1b5609</sessionId>
   <success>true</success>
   <visitorKey>1104E067D5B4F3994553</visitorKey>
</LoginResult>
Last modified date: 12/17/2021