# \_getInvoiceStatuses

Returns the Invoice Statuses of Jobs

### Parameters

#### ids

The IDs of the Jobs which Invoice Statuses will be retrieved from.

### Example

```
FM_api('Jobs_getInvoiceStatuses', ['ids' => ['592012','592013']])
```

### Result

#### On Success

For each Job, the data returned is the following in this order:\
The Status of the Invoice: (Quoted => 0, Invoiced => 1, Paid => 2, Cancelled => 3,\
Credit Note => 4, DRAFT => 5)\
The date that the Invoice was sent to an Email\
The Invoice Number\
The due date of the Invoice

```
{"592012":["1","2024-08-20 14:22:06","123","1726099200"],"592013":["1","2024-08-20 14:27:23","124","1724976000"]}
```

#### On Failure

If the "ids" parameter is not set:

```
{"error":"missing or invalid parameter: ids"}
```

If there are no Jobs with Invoices:

```
[]
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.fieldmotion.com/fieldmotion-api-docs/jobs/_getinvoicestatuses.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
