LetsBot Μενού
Ξεκινήστε Ελληνικά Γλώσσα

Meta Business Partner Εταιρεία εγγεγραμμένη στο Ηνωμένο Βασίλειο

Γλώσσα

CRM · Endpoint API

GET /api/v1/crm/contacts/schema Νέο

Contact fields, filters and sorts

The lists-engine catalogue for contact lists: every field with its type, whether it can be filtered or sorted, its filter operators and options (for e…

The lists-engine catalogue for contact lists: every field with its type, whether it can be filtered or sorted, its filter operators and options (for example the lifecycle stage ids). Scope: crm.

Παράδειγμα αιτήματος

curl -G "https://your-workspace.letsbot.net/api/v1/crm/contacts/schema" \
  -H "X-Zapier-Api-Key: YOUR_WORKSPACE_API_KEY" \
  -H "Accept: application/json"
const response = await fetch("https://your-workspace.letsbot.net/api/v1/crm/contacts/schema", {
  method: "GET",
  headers: {
    "X-Zapier-Api-Key": "YOUR_WORKSPACE_API_KEY",
    "Accept": "application/json",
  },
});

const data = await response.json();
console.log(data);
<?php

$ch = curl_init('https://your-workspace.letsbot.net/api/v1/crm/contacts/schema');

curl_setopt_array($ch, [
    CURLOPT_CUSTOMREQUEST => 'GET',
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'X-Zapier-Api-Key: YOUR_WORKSPACE_API_KEY',
        'Accept: application/json',
    ],
]);

$data = json_decode(curl_exec($ch), true);
curl_close($ch);

print_r($data);
import requests

response = requests.request(
    "GET",
    "https://your-workspace.letsbot.net/api/v1/crm/contacts/schema",
    headers={
        "X-Zapier-Api-Key": "YOUR_WORKSPACE_API_KEY",
        "Accept": "application/json",
    },
)

print(response.json())

Απαντήσεις

Schema200
{
  "success": true,
  "data": {
    "fields": [
      {
        "key": "name",
        "label": "Name",
        "type": "text",
        "filterable": true,
        "sortable": true,
        "operators": [
          "contains",
          "is",
          "is_empty",
          "is_not_empty"
        ],
        "options": []
      },
      {
        "key": "email",
        "label": "Email",
        "type": "text",
        "filterable": true,
        "sortable": false,
        "operators": [
          "contains",
          "is",
          "is_empty",
          "is_not_empty"
        ],
        "options": []
      },
      {
        "key": "lifecycle",
        "label": "Lifecycle stage",
        "type": "select",
        "filterable": true,
        "sortable": true,
        "operators": [
          "is",
          "is_not"
        ],
        "options": [
          {
            "value": 1,
            "label": "Subscriber"
          },
          {
            "value": 2,
            "label": "Lead"
          },
          {
            "value": 3,
            "label": "Customer"
          }
        ]
      }
    ],
    "sorts": [
      "name",
      "created_at",
      "last_activity_at"
    ],
    "default_sort": {
      "key": "last_activity_at",
      "dir": "desc"
    }
  }
}

Έτοιμοι όποτε είστε κι εσείς

Δοκιμάστε αυτό το endpoint με τον δικό σας αριθμό

Το API λειτουργεί κατά τη δωρεάν δοκιμή. Δημιουργήστε λογαριασμό, συνδέστε τον αριθμό WhatsApp σας και αντιγράψτε το κλειδί σας από API → Δεδομένα ταυτοποίησης.