> For the complete documentation index, see [llms.txt](https://timetackle.gitbook.io/tackle/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://timetackle.gitbook.io/tackle/api-categories/crm.md).

# CRM

## POST /crm/accounts

> Create or update CRM accounts and deals

```json
{"openapi":"3.0.3","info":{"title":"Tackle API","version":"1.0.0"},"servers":[{"url":"https://api.timetackle.com/external-api/v1"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{},"parameters":{"X-Tackle-App-Type":{"in":"header","name":"X-Tackle-App-Type","required":true,"schema":{"$ref":"#/components/schemas/AppTypeEnum"},"description":"Specifies the type of the application making the request. Must be one of the predefined values."}},"schemas":{"AppTypeEnum":{"type":"string","enum":["SALESFORCE","HUB_SPOT","DEEL","GOOGLE_CALENDAR","ZOHO_CALENDAR","OUTLOOK_CALENDAR"]},"Account":{"type":"object","properties":{"id":{"type":"string"},"nativeId":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"industry":{"type":"string"},"website":{"type":"string"},"createdTime":{"type":"string","format":"date-time"},"modifiedTime":{"type":"string","format":"date-time"},"phone":{"type":"string"},"annualRevenue":{"type":"number","nullable":true},"numberOfEmployees":{"type":"integer"},"address":{"type":"object","properties":{"street":{"type":"string"},"postalCode":{"type":"string"},"city":{"type":"string"},"state":{"type":"string"},"country":{"type":"string"}}},"additional":{"type":"object"},"deals":{"type":"array","items":{"$ref":"#/components/schemas/Deal"}}}},"Deal":{"type":"object","properties":{"id":{"type":"string"},"nativeId":{"type":"string"},"name":{"type":"string"},"stage":{"type":"string"},"isWon":{"type":"boolean"},"isClosed":{"type":"boolean"},"createdTime":{"type":"string","format":"date-time"},"modifiedTime":{"type":"string","format":"date-time"},"amount":{"type":"number"},"expectedRevenue":{"type":"number"},"closeDate":{"type":"string","format":"date"},"probability":{"type":"number"},"additional":{"type":"object"}}}}},"paths":{"/crm/accounts":{"post":{"summary":"Create or update CRM accounts and deals","parameters":[{"$ref":"#/components/parameters/X-Tackle-App-Type"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Account"}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"data":{"nullable":true},"error":{"nullable":true}}}}}}}}}}}
```

## POST /crm/accounts/delete

> Delete CRM accounts

```json
{"openapi":"3.0.3","info":{"title":"Tackle API","version":"1.0.0"},"servers":[{"url":"https://api.timetackle.com/external-api/v1"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{},"parameters":{"X-Tackle-App-Type":{"in":"header","name":"X-Tackle-App-Type","required":true,"schema":{"$ref":"#/components/schemas/AppTypeEnum"},"description":"Specifies the type of the application making the request. Must be one of the predefined values."}},"schemas":{"AppTypeEnum":{"type":"string","enum":["SALESFORCE","HUB_SPOT","DEEL","GOOGLE_CALENDAR","ZOHO_CALENDAR","OUTLOOK_CALENDAR"]}}},"paths":{"/crm/accounts/delete":{"post":{"summary":"Delete CRM accounts","parameters":[{"$ref":"#/components/parameters/X-Tackle-App-Type"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"nativeId":{"type":"string"}}}}}}},"responses":{"200":{"description":"Success"}}}}}}
```

## POST /crm/deals/update

> Update CRM deals

```json
{"openapi":"3.0.3","info":{"title":"Tackle API","version":"1.0.0"},"servers":[{"url":"https://api.timetackle.com/external-api/v1"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{},"parameters":{"X-Tackle-App-Type":{"in":"header","name":"X-Tackle-App-Type","required":true,"schema":{"$ref":"#/components/schemas/AppTypeEnum"},"description":"Specifies the type of the application making the request. Must be one of the predefined values."}},"schemas":{"AppTypeEnum":{"type":"string","enum":["SALESFORCE","HUB_SPOT","DEEL","GOOGLE_CALENDAR","ZOHO_CALENDAR","OUTLOOK_CALENDAR"]},"UpdateDeal":{"type":"object","properties":{"id":{"type":"string"},"nativeId":{"type":"string"},"name":{"type":"string"},"stage":{"type":"string"},"isWon":{"type":"boolean"},"isClosed":{"type":"boolean"},"createdTime":{"type":"string","format":"date-time"},"modifiedTime":{"type":"string","format":"date-time"},"amount":{"type":"number"},"expectedRevenue":{"type":"number"},"closeDate":{"type":"string","format":"date"},"probability":{"type":"number"},"additional":{"type":"object"},"associations":{"type":"object","properties":{"accountIds":{"type":"array","items":{"type":"string"}}}}}}}},"paths":{"/crm/deals/update":{"post":{"summary":"Update CRM deals","parameters":[{"$ref":"#/components/parameters/X-Tackle-App-Type"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UpdateDeal"}}}}},"responses":{"200":{"description":"Success"}}}}}}
```

## POST /crm/deals/delete

> Delete CRM deals

```json
{"openapi":"3.0.3","info":{"title":"Tackle API","version":"1.0.0"},"servers":[{"url":"https://api.timetackle.com/external-api/v1"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{},"parameters":{"X-Tackle-App-Type":{"in":"header","name":"X-Tackle-App-Type","required":true,"schema":{"$ref":"#/components/schemas/AppTypeEnum"},"description":"Specifies the type of the application making the request. Must be one of the predefined values."}},"schemas":{"AppTypeEnum":{"type":"string","enum":["SALESFORCE","HUB_SPOT","DEEL","GOOGLE_CALENDAR","ZOHO_CALENDAR","OUTLOOK_CALENDAR"]}}},"paths":{"/crm/deals/delete":{"post":{"summary":"Delete CRM deals","parameters":[{"$ref":"#/components/parameters/X-Tackle-App-Type"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"nativeId":{"type":"string"}}}}}}},"responses":{"200":{"description":"Success"}}}}}}
```

## POST /crm/config

> Sync (Create/Update) CRM Config

```json
{"openapi":"3.0.3","info":{"title":"Tackle API","version":"1.0.0"},"servers":[{"url":"https://api.timetackle.com/external-api/v1"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{},"parameters":{"X-Tackle-App-Type":{"in":"header","name":"X-Tackle-App-Type","required":true,"schema":{"$ref":"#/components/schemas/AppTypeEnum"},"description":"Specifies the type of the application making the request. Must be one of the predefined values."}},"schemas":{"AppTypeEnum":{"type":"string","enum":["SALESFORCE","HUB_SPOT","DEEL","GOOGLE_CALENDAR","ZOHO_CALENDAR","OUTLOOK_CALENDAR"]},"CRMConfig":{"type":"object","properties":{"key":{"type":"string","description":"key is the unique identifier here"},"name":{"type":"string"},"custom":{"type":"boolean"},"type":{"type":"string"},"options":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"name":{"type":"string"}}}},"creatable":{"type":"boolean"},"updatable":{"type":"boolean"},"required":{"type":"boolean","default":false},"universal":{"type":"boolean"}}}}},"paths":{"/crm/config":{"post":{"summary":"Sync (Create/Update) CRM Config","parameters":[{"$ref":"#/components/parameters/X-Tackle-App-Type"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CRMConfig"}}}},"responses":{"200":{"description":"Success"}}}}}}
```

## POST /crm/config/delete

> Delete entire CRM Config

```json
{"openapi":"3.0.3","info":{"title":"Tackle API","version":"1.0.0"},"servers":[{"url":"https://api.timetackle.com/external-api/v1"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{},"parameters":{"X-Tackle-App-Type":{"in":"header","name":"X-Tackle-App-Type","required":true,"schema":{"$ref":"#/components/schemas/AppTypeEnum"},"description":"Specifies the type of the application making the request. Must be one of the predefined values."}},"schemas":{"AppTypeEnum":{"type":"string","enum":["SALESFORCE","HUB_SPOT","DEEL","GOOGLE_CALENDAR","ZOHO_CALENDAR","OUTLOOK_CALENDAR"]}}},"paths":{"/crm/config/delete":{"post":{"summary":"Delete entire CRM Config","parameters":[{"$ref":"#/components/parameters/X-Tackle-App-Type"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"key":{"type":"string"},"name":{"type":"string"}}}}}},"responses":{"200":{"description":"Success"}}}}}}
```

## POST /crm/users

> Sync CRM users

```json
{"openapi":"3.0.3","info":{"title":"Tackle API","version":"1.0.0"},"servers":[{"url":"https://api.timetackle.com/external-api/v1"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{},"parameters":{"X-Tackle-App-Type":{"in":"header","name":"X-Tackle-App-Type","required":true,"schema":{"$ref":"#/components/schemas/AppTypeEnum"},"description":"Specifies the type of the application making the request. Must be one of the predefined values."}},"schemas":{"AppTypeEnum":{"type":"string","enum":["SALESFORCE","HUB_SPOT","DEEL","GOOGLE_CALENDAR","ZOHO_CALENDAR","OUTLOOK_CALENDAR"]},"CRMUser":{"type":"object","properties":{"id":{"type":"string"},"firstName":{"type":"string"},"lastName":{"type":"string"},"email":{"type":"string"},"createdTime":{"type":"string","format":"date-time"},"modifiedTime":{"type":"string","format":"date-time"},"additional":{"type":"object"}}}}},"paths":{"/crm/users":{"post":{"summary":"Sync CRM users","parameters":[{"$ref":"#/components/parameters/X-Tackle-App-Type"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CRMUser"}}}}},"responses":{"200":{"description":"Success"}}}}}}
```
