Quickstart
Make your first successful Yurbi API call: log in, get a token, and use it.
1. Log in to get a session token
Every call needs a session token. Get one by posting your credentials to
DoLogin. Replace the host with your own Yurbi server.
curl -X POST "https://your-yurbi-server.com/api/login/DoLogin" \
-H "Content-Type: application/json" \
-d '{
"bolForceLogin": true,
"isGuest": false,
"UserId": "admin",
"UserPassword": "your-password"
}'
A successful response has ErrorCode: 0 and your token at
LoginSession.SessionToken:
{
"ErrorCode": 0,
"ErrorMessage": "",
"LoginSession": {
"SessionToken": "LVPACMJFBMZKUHRIXMQSTUZUY",
"isGuestSession": false,
"SessionExpir": "2025-09-02T13:27:43.382837-04:00"
}
}
Bad credentials return ErrorCode: 101 with "Login Failed - Username or Password
is invalid." and a null LoginSession.
2. Use the token on a call
Pass the token in the JSON body of every other request — it is not an HTTP header. For example, list the users on the instance:
curl -X POST "https://your-yurbi-server.com/api/Contact/GetContactList" \
-H "Content-Type: application/json" \
-d '{ "sessionToken": "LVPACMJFBMZKUHRIXMQSTUZUY" }'
That's the whole pattern: log in once, reuse the token.
Linux/Docker vs Windows paths. These examples use the Linux/Docker base
/api. On Windows (IIS), Yurbi is served under/yurbi, so the path is/yurbi/api/...(e.g./yurbi/api/login/DoLogin). See Conventions, or just use the platform toggle on the Reference page.
3. Try it without writing code
Open the API Reference, paste your Base URL and token into the bar at the top, and every code sample updates with your values. Hit Send to run a call live against your server, or copy the ready-to-run cURL.
Next
- Authentication & sessions — keeping tokens alive, logging out.
- Conventions & errors — the rules shared by every endpoint.
- Embedding guide — put a dashboard in your app.