# Pabau

> Read clients, appointments, leads, locations and services in Pabau.

App · 20 actions. Web page: https://docs.lodol.com/docs/integrations/pabau

## Actions

### Get appointment

Get appointment.

**Inputs**

- Appointment (`appointment_id`, number, required): Appointment id.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "appointments": [
      {
        "client": [
          {}
        ],
        "communications": {},
        "custom_fields": [
          {}
        ],
        "dates": {},
        "details": {},
        "issued_to": {},
        "resources": [
          {}
        ],
        "service": [
          {}
        ]
      }
    ],
    "status": true,
    "total": 1
  }
}
```

### Get client balance

Get client balance.

**Inputs**

- Contact (`contact_id`, number, required): Contact id.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "balance": 1,
    "loyalty_points": 1,
    "packages": [
      {}
    ],
    "success": true,
    "vouchers": [
      {}
    ]
  }
}
```

### Get invoice

Get invoice.

**Inputs**

- Invoice ID (`invoice_id`, number, required): Invoice id.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "invoices": [
      {
        "appointment": {},
        "client": [
          {}
        ],
        "details": {},
        "fees": {},
        "items": [
          {}
        ],
        "location": [
          {}
        ],
        "payments": [
          {}
        ]
      }
    ],
    "success": true,
    "total": 1
  }
}
```

### Get lead

Get lead.

**Inputs**

- Lead ID (`lead_id`, number, required): Lead id.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "catalog": [
      {}
    ],
    "expiration": "example",
    "lead_stages": [
      {
        "id": "example",
        "status_name": "example"
      }
    ],
    "leads": [
      {
        "Salutation": "example",
        "avatar": "example",
        "contact_id": "example",
        "description": "example",
        "email": "example",
        "first_name": "example",
        "gender": "example",
        "last_name": "example",
        "lead_id": 1,
        "lead_source": 1,
        "lead_status": "example",
        "mobile": "example",
        "owner_id": 1,
        "phone": "example"
      }
    ],
    "success": true,
    "tenant": "example",
    "token": "example",
    "total": 1
  }
}
```

### List all appointments

List all appointments.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "appointments": [
      {
        "client": [
          {}
        ],
        "communications": {},
        "custom_fields": [
          {}
        ],
        "dates": {},
        "details": {},
        "issued_to": {},
        "resources": [
          {}
        ],
        "service": [
          {}
        ]
      }
    ],
    "status": true,
    "total": 1
  }
}
```

### List appointments

List appointments.

**Inputs**

- Page (`page`, number): Page. At least 1.
- Per page (`per_page`, number): Per page. From 1 to 100.
- Order (`order`, text): Order. One of: `ASC`, `DESC`.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "appointments": [
      {
        "client": [
          {}
        ],
        "communications": {},
        "custom_fields": [
          {}
        ],
        "dates": {},
        "details": {},
        "id": 1,
        "issued_to": {},
        "resources": [
          {}
        ],
        "service": [
          {}
        ]
      }
    ],
    "status": true,
    "total": 1
  }
}
```

### List client appointments

List client appointments.

**Inputs**

- Contact (`contact_id`, number, required): Contact id.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "appointments": [
      {
        "client": [
          {}
        ],
        "communications": {},
        "custom_fields": [
          {}
        ],
        "dates": {},
        "details": {},
        "issued_to": {},
        "resources": [
          {}
        ],
        "service": [
          {}
        ]
      }
    ],
    "status": true,
    "total": 1
  }
}
```

### List client problems

List client problems.

**Inputs**

- Contact (`contact_id`, number, required): Contact id.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "diagnosis_date": "example",
        "icd10": "example",
        "icd9": "example",
        "icd_version": "example",
        "id": 1,
        "name": "example",
        "notes": "example",
        "related_appointments": "example",
        "snomed": "example",
        "status": 1
      }
    ],
    "success": true,
    "total": 1
  }
}
```

### List clients

List clients.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "clients": [
      {
        "address": {},
        "allergies": [
          {}
        ],
        "appointments": [
          {}
        ],
        "client_insights": [
          {}
        ],
        "communications": {},
        "created": {},
        "custom": [
          {}
        ],
        "details": {},
        "id": 1,
        "insurance": {},
        "relationships": [
          {}
        ]
      }
    ],
    "success": true,
    "total": 1
  }
}
```

### List custom fields

List custom fields.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "data": [
          {}
        ],
        "dataType": "example",
        "id": 1,
        "isArchived": true,
        "isRequired": true,
        "name": "example",
        "objectType": "example"
      }
    ],
    "success": true,
    "total": 1
  }
}
```

### List invoices

List invoices.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "invoices": [
      {
        "client": [
          {}
        ],
        "details": {},
        "fees": {},
        "items": [
          {}
        ],
        "location": [
          {}
        ],
        "payments": [
          {}
        ]
      }
    ],
    "success": true,
    "total": 1
  }
}
```

### List lead activity

List lead activity.

**Inputs**

- Lead ID (`lead_id`, number, required): Lead id.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "content": "example",
        "date": "example",
        "type": "example",
        "user": "example"
      }
    ],
    "success": true,
    "total": 1
  }
}
```

### List lead lost reasons

List lead lost reasons.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "id": 1,
        "name": "example"
      }
    ],
    "success": true
  }
}
```

### List lead pipelines

List lead pipelines.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "pipelines": [
      {
        "id": 1,
        "is_default": 1,
        "order": 1,
        "pipeline_name": "example",
        "stages": [
          {}
        ]
      }
    ],
    "status": true,
    "total": 1
  }
}
```

### List leads

List leads.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "leads": {
      "AndrejPipeLineTest2": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "AndrejPipeLineTest3": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Test1": {},
        "Test2": {}
      },
      "AndrejPipeLineTest5": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Test123": {},
        "Test246": {}
      },
      "GENERAL PIPELINE": {
        "3RD EMAIL SENT": {},
        "Contact Made": {},
        "EMAIL SENT ": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "Hello Pipeline ": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "Lilly Park 1": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {},
        "Test 1": {},
        "Test 2": {}
      },
      "MEL CLINIC Pipeline": {
        "Attempted to Contact": {},
        "Contacted": {},
        "Open Lead": {}
      },
      "November Pipeline": {
        "Book appointment ": {},
        "Confirm Booking date": {},
        "Follow-up email": {},
        "Phone Call": {},
        "Send Social Survey": {},
        "Send email+offer": {}
      },
      "S pipeline": {
        "Ask for balance ": {},
        "Asked for deposit": {},
        "Deposit paid": {},
        "S1: Provisional booking for a procedure": {},
        "Sent confirmation": {}
      },
      "Second Pipeline for leads": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {},
        "second email sent": {}
      },
      "Test Donika": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "Test Ivche": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "Test Ivche6": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "new stage": {},
        "test 555": {},
        "test6": {}
      },
      "Test12457": {
        "": {},
        "Add Strange Name ": {},
        "Bla": {},
        "Contact Made": {},
        "New Lead": {},
        "This is again bla": {},
        "strange": {}
      },
      "another pipe 2": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {},
        "redon 223": {}
      },
      "botox pipeline": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "deafult": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "default": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book.": {}
      },
      "final pipelinee": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {},
        "final stage hehe": {},
        "ringo stage": {}
      },
      "hey": {
        "BEII": {},
        "Contact Made": {},
        "DEDEDEDEDE": {},
        "EFAFAEFAEF": {},
        "EFAWFFAF": {},
        "EFRGFTRGTGT": {},
        "FEFEAFAEF": {},
        "FEFEAFEAF": {},
        "FSAFASFSAF": {},
        "HOW ": {},
        "New Lead": {},
        "Other": {},
        "QFDEQFAFA": {},
        "Quote Sent": {},
        "Ready to Book": {},
        "SEOCOND": {},
        "THERE": {},
        "WHY": {},
        "WSWSWS": {},
        "eaffaefaef": {},
        "efafaefae": {}
      },
      "new pipeline": {
        "": {},
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "new redon 2": {
        "": {},
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "new test pipe": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "redon 2 pipe": {
        "": {},
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {},
        "redon 1": {}
      },
      "redon pipe 2": {
        "": {},
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "redon pipeline": {
        "": {},
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      },
      "redon pipeline test": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {},
        "stage test 1": {},
        "stage test 2": {}
      },
      "second redon test": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {},
        "redon 1": {},
        "redon 2 test": {}
      },
      "testing": {
        "": {},
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {},
        "ba": {}
      },
      "testing this": {
        "Contact Made": {},
        "New Lead": {},
        "Quote Sent": {},
        "Ready to Book": {}
      }
    },
    "status": true,
    "total": 1
  }
}
```

### List locations

List locations.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "locations": [
      {
        "address": {},
        "assigned_employees": [
          {}
        ],
        "default": 1,
        "id": 1,
        "location_name": "example",
        "working_hours": [
          {}
        ]
      }
    ],
    "success": true,
    "total": 1
  }
}
```

### List rooms

List rooms.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "resources": [
      {
        "id": 1,
        "room_name": "example"
      }
    ],
    "success": true,
    "total": 1
  }
}
```

### List schedules

List schedules.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "catalog": [
      {}
    ],
    "expiration": "example",
    "rota_permission": "example",
    "schedules": [
      {
        "employee_id": "example",
        "end_time": "example",
        "id": "example",
        "is_holiday": 1,
        "location": "example",
        "shift_date": "example",
        "start_time": "example",
        "user_id": "example",
        "user_name": "example"
      }
    ],
    "success": true,
    "tenant": "example",
    "token": "example",
    "total": 1
  }
}
```

### List services

List services.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {}
}
```

### List users

List users.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Pabau.

**Example output**

```json
{
  "data": {
    "success": true,
    "total": 1,
    "users": [
      {
        "assigned_locations": [
          {}
        ],
        "assigned_services": [
          {}
        ],
        "avatar": "example",
        "bio": "example",
        "full_name": "example",
        "id": 1,
        "job_title": "example",
        "status": "example",
        "username": "example"
      }
    ]
  }
}
```
