Skip to content
TapLogic API
Italiano

Quickstart in 5 minutes

Create a test key, read your tags, assign one and receive the first scan on your server.

  1. Create a test key

    In the TapLogic app open Settings → API and webhooks → API keys and press “New key”. Choose Test mode and the scopes tags:read, tags:write, scans:read, webhooks:write. The key is shown only once: copy it and store it in an environment variable.

    export TAPLOGIC_API_KEY="tl_test_4eC39HqLyjWDarjtT1zdp7dc"
  2. Read your tags

    A test key sees only demo tags: you can try everything without touching real customer tags.

    curl "https://api.taplogic.it/v1/tags?limit=10" \
      -H "Authorization: Bearer $TAPLOGIC_API_KEY"
    {
      "object": "list",
      "data": [
        {
          "id": "cm3tag0001",
          "object": "tag",
          "code": "K7P2QX9M",
          "url": "https://t.taplogic.it/K7P2QX9M",
          "email_address": "k7p2qx9m@m.taplogic.it",
          "chip_type": "ntag213",
          "status": "assigned",
          "product": { "id": "cm3prd0001", "type": "keychain", "name": "Portachiavi" },
          "member_id": null,
          "action_id": null,
          "location": null,
          "livemode": false,
          "created_at": "2026-11-18T09:12:00.000Z",
          "updated_at": "2026-11-18T09:12:00.000Z"
        }
      ],
      "has_more": false,
      "next_cursor": null
    }
  3. Assign a tag to a person

    Take a member id from GET /members and pass it as member_id. The Idempotency-Key header makes it safe to repeat the request if the network drops.

    curl -X PATCH "https://api.taplogic.it/v1/tags/cm3tag0001" \
      -H "Authorization: Bearer $TAPLOGIC_API_KEY" \
      -H "Idempotency-Key: assegna-K7P2QX9M-1" \
      -H "Content-Type: application/json" \
      -d '{"member_id":"cm3mbr0001"}'
  4. Receive scans in real time

    Register a webhook endpoint for tag.scanned. The response holds the whsec_… signing secret: use it to verify each event (see Webhooks). Then send a test event.

    curl -X POST "https://api.taplogic.it/v1/webhooks" \
      -H "Authorization: Bearer $TAPLOGIC_API_KEY" \
      -H "Idempotency-Key: endpoint-principale" \
      -H "Content-Type: application/json" \
      -d '{"url":"https://esempio.it/webhook/taplogic","enabled_events":["tag.scanned"]}'
    curl -X POST "https://api.taplogic.it/v1/webhooks/cm3whk0001/test" \
      -H "Authorization: Bearer $TAPLOGIC_API_KEY"
    {
      "id": "evt_9f3Kd2LmQx81ZpRt0aBcYvWs",
      "object": "event",
      "type": "tag.scanned",
      "api_version": "2026-11-18",
      "created": 1763457600,
      "livemode": false,
      "data": {
        "object": {
          "id": "cm3scn0001",
          "object": "scan",
          "tag_id": "cm3tag0001",
          "code": "K7P2QX9M",
          "occurred_at": "2026-11-18T09:20:00.000Z",
          "outcome": "ok",
          "action_type": "whatsapp",
          "destination": "https://wa.me/390212345678",
          "location_source": "network",
          "member_id": "cm3mbr0001",
          "product_id": "cm3prd0001",
          "country": "IT",
          "city": "Milano",
          "livemode": false
        }
      }
    }
  5. Read the scan history

    Filter by period, tag or member. Times are UTC, ISO 8601.

    curl "https://api.taplogic.it/v1/scans?from=2026-11-01T00:00:00Z&tag=cm3tag0001" \
      -H "Authorization: Bearer $TAPLOGIC_API_KEY"

Done. When you are ready, create a Live key with the same scopes: the code does not change. Continue with Errors and Pagination.