1. Home
  2. Docs
  3. Managers
  4. API Documentation
  5. API resources
  6. Users
  7. Add

Add

Published 26 January 2026, Updated 26 January 2026

POST /users/add

Purpose: create a new user.

Access:

  • read-write
  • admin

Payload: add format above.

Additional fields:

  • Join fields are not insertable unless they are real columns in the base table.

Allowed fields (from config):

  • lastnamegivennameaddresslicencedobemailphonecellinactive

    Sample payload:

    {
      "lastname": "Doe",
      "givenname": "Jane",
      "address": "123 Main St",
      "licence": "LIC-123",
      "dob": "1990-01-01",
      "email": "jane@example.com",
      "phone": "+1-555-0100",
      "cell": "+1-555-0101",
      "inactive": 0
    }

    Response:

    {
      "meta": { "status": 201, "error": null },
      "data": {
        "id": 1,
        "lastname": "Doe",
        "givenname": "Jane",
        "email": "jane@example.com"
      }
    }

    Examples (curl):

    curl -X POST https://example.com/api/v1/prod/users/add \
      -H "Authorization: Bearer YOUR_TOKEN" \
      -H "X-Client: LTW-API" \
      -H "Content-Type: application/json" \
      -d "{\"lastname\":\"Doe\",\"givenname\":\"Jane\",\"email\":\"jane@example.com\"}"

    Examples (PHP):

    <?php
    $url = 'https://example.com/api/v1/prod/users/add';
    $payload = json_encode([
        'lastname' => 'Doe',
        'givenname' => 'Jane',
        'email' => 'jane@example.com',
    ]);
    
    $ch = curl_init($url);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_POST, true);
    curl_setopt($ch, CURLOPT_HTTPHEADER, [
        'Authorization: Bearer YOUR_TOKEN',
        'X-Client: LTW-API',
        'Content-Type: application/json',
    ]);
    curl_setopt($ch, CURLOPT_POSTFIELDS, $payload);
    
    $response = curl_exec($ch);
    if ($response === false) {
        throw new RuntimeException(curl_error($ch));
    }
    curl_close($ch);
    
    echo $response;

    Examples (Node.js):

    const fetch = require('node-fetch');
    
    async function addUser() {
      const res = await fetch('https://example.com/api/v1/prod/users/add', {
        method: 'POST',
        headers: {
          Authorization: 'Bearer YOUR_TOKEN',
          'X-Client': 'LTW-API',
          'Content-Type': 'application/json',
        },
        body: JSON.stringify({
          lastname: 'Doe',
          givenname: 'Jane',
          email: 'jane@example.com',
        }),
      });
    
      if (!res.ok) {
        throw new Error(`HTTP ${res.status}`);
      }
    
      const data = await res.json();
      console.log(data);
    }
    
    addUser().catch(console.error);
    Was this article helpful to you? Yes No