> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hotglue.com/llms.txt
> Use this file to discover all available pages before exploring further.

# runJob

> Run a job for a given tenant

## runJob

The `runJob` function starts a job for the provided `tenantId`, `flowId`, and `connectorId`.

### Parameters:

* **tenantId**: `string`
  * A string identifier for the tenant.
* **flowId**: `string`
  * A string identifier for the flow.
* **connectorId**: `string`
  * A string identifier for the connector.
* **jobType**: `'write' | 'read'` (optional)
  * For bidirectional flows only, specify job type, either 'write' or 'read'.
* **startDate**: `string` (optional)
  * An optional date string to specify the start date of the job.

### Example:

```javascript theme={null}
const newJob = runJob('exampleTenantId', 'abdc123', 'salesforce', undefined, '2024-10-12');
console.log(newJob);
```
