# Login

`POST /v2/login`

**Base URLs:**

- Sandbox: `https://api.sandbox.bobpay.co.za`
- Production: `https://api.bobpay.co.za`

## Example request

```bash
curl -X POST "https://api.sandbox.bobpay.co.za/v2/login" \
  -H "content-type: application/json" \
  -d '{
    "email": "your-email@example.com",
    "password": "your-password"
}'
```

Bob Pay uses **Bearer Token** authentication.

After logging in, a JWT token is returned. Add this token as a header to all your API calls, e.g. `"Authorization": "Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."`

The token expires after 30 days, after which a new token needs to be generated.

Log in with the email address and password of your [sandbox account](https://sandbox.bobpay.co.za/).
