# Forcemanager

ForceManager is a mobile-first CRM designed to enhance sales team productivity by providing real-time insights and streamlined management of customer interactions.

- **Category:** crm
- **Auth:** API_KEY
- **Composio Managed App Available?** N/A
- **Tools:** 20
- **Triggers:** 0
- **Slug:** `FORCEMANAGER`
- **Version:** 20260227_00

## Tools

### Delete Activity

**Slug:** `FORCEMANAGER_DELETE_ACTIVITY`

Delete an existing activity by ID. Tries multiple base hosts and path variants to maximize compatibility across environments and gateways.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | Activity identifier (positive integer) |
| `api_version` | integer | No | ForceManager API version to use (sent via X-FM-API-Version header) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Delete Company

**Slug:** `FORCEMANAGER_DELETE_COMPANY`

Tool to delete a company by its ForceManager ID. Use when you need to remove an existing company from the system.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | Company identifier (positive integer) |
| `api_version` | integer | No | ForceManager API version to use (sent via X-FM-API-Version header) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Delete Contact

**Slug:** `FORCEMANAGER_DELETE_CONTACT`

Permanently deletes a contact from ForceManager by its unique ID. This action removes the specified contact and all associated data. The operation is irreversible. The action automatically tries multiple API endpoint combinations to ensure compatibility across different ForceManager deployments and configurations. Returns the HTTP status code and any response message from the API. A successful deletion typically returns a 200 status code.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | The unique ID of the contact to delete. Must be a positive integer that represents an existing contact in ForceManager. |
| `api_version` | integer | No | Optional API version number to use for this request. If specified, it will be sent in the X-FM-API-Version header. Leave empty to use the default API version. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Delete Sales Order

**Slug:** `FORCEMANAGER_DELETE_SALES_ORDER`

Delete a sales order by ID using ForceManager REST API. Tries multiple base hosts and path variants to maximize compatibility across environments. Accepts successful HTTP status codes (< 300) even when the response is non-JSON, capturing response text.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | The unique identifier of the sales order to delete |
| `api_version` | integer | No | ForceManager API version to use. If specified, sends X-FM-API-Version header with the request |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Delete Sales Order Line

**Slug:** `FORCEMANAGER_DELETE_SALES_ORDER_LINE`

Delete a sales order line by ID. Attempts deletion across multiple ForceManager API hosts and path variations to ensure compatibility. Returns detailed information about the deletion result, including any messages or status codes from the API. Use this when you need to remove a specific sales order line item from the system.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | The unique identifier of the sales order line to delete. Must be a positive integer representing an existing sales order line ID. |
| `api_version` | integer | No | ForceManager API version to use for this request. If specified, sends X-FM-API-Version header. Leave unset to use the default API version. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Delete Master Data Value

**Slug:** `FORCEMANAGER_DELETE_VALUE`

Delete a master-data value (Z_ table) by ID using ForceManager REST API. Tries multiple base hosts and path variants to maximize compatibility across environments. Accepts successful HTTP status codes (< 300) even when the response is HTML instead of JSON, capturing the response text as a message. Also retries sending authentication headers as query parameters on HTTP 401 as some gateways expect them in query string.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | Identifier of the master-data value to delete |
| `api_version` | integer | No | Optional ForceManager API version to use (sent via X-FM-API-Version) |
| `resourceName` | string | Yes | Name of the Z_ master data table containing the value (e.g., Z_Test) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Delete View

**Slug:** `FORCEMANAGER_DELETE_VIEW`

Delete a saved view (custom filter) by its ID. Views in ForceManager are saved filter configurations that users create to quickly access filtered lists of entities (accounts, activities, opportunities, etc.). This action permanently removes a view that the authenticated user has permission to delete. **Use Cases:** - Remove outdated or unused custom filters - Clean up views after organizational changes - Programmatically manage view lifecycle **Requirements:** - Valid view ID that exists in the system - Appropriate permissions to delete the view - The view must be owned by or shared with the authenticated user **Note:** This action tries multiple ForceManager API endpoints to maximize compatibility across different deployment environments and API versions.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | string | Yes | ID of the saved view (custom filter) to delete. A view in ForceManager represents a saved filter configuration for entities like accounts, activities, or opportunities. The ID must match an existing view that the authenticated user has permission to delete. |
| `api_version` | integer | No | ForceManager API version to use (sent via X-FM-API-Version header). Optional - defaults to the API's default version if not specified. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Get Activity

**Slug:** `FORCEMANAGER_GET_ACTIVITY`

Retrieves a single activity by its ID from ForceManager CRM. Use this tool when you need to: - Fetch details of a specific activity by its ID - Check if an activity exists - Retrieve activity data including comments, dates, linked contacts/accounts, and location info The action attempts multiple ForceManager API endpoints to ensure compatibility across different API versions and deployment configurations. Returns found=False if the activity does not exist or cannot be retrieved. Authentication is handled automatically via headers from the connected account.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | string | Yes | The unique identifier of the activity to retrieve. Accepts numeric IDs (e.g., '1', '12345') or alphanumeric external IDs (e.g., 'abc123'). This is passed as a path parameter in the API request. |
| `api_version` | integer | No | ForceManager API version to use. If not specified, the API will use the default version. Sent via X-FM-API-Version header. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Get Company

**Slug:** `FORCEMANAGER_GET_COMPANY`

Retrieve a single company by its ID from ForceManager. Returns company details when found, or an empty entity with found=False when the company doesn't exist or the API returns non-JSON content. The action automatically tries multiple ForceManager API endpoints for maximum compatibility. Use this to fetch company information including name, address, contact details, and custom fields. Check the 'found' field to determine if the company exists.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | string | Yes | The unique identifier of the company to retrieve. Can be a numeric ID (e.g., '5000') or alphanumeric external ID |
| `api_version` | integer | No | Optional API version number to use (sent via X-FM-API-Version header). Leave unset to use the default version |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Get Internal ID

**Slug:** `FORCEMANAGER_GET_INTERNAL_ID`

Tool to retrieve ForceManager internal IDs mapping for a given externalId and entity type. This action calls the documented endpoint /api/internalid with required authentication headers and optional pagination/version headers. It tries multiple base hosts to avoid HTML app shell responses and gracefully handles non-JSON responses and error codes by returning empty results instead of failing the execution.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `page` | integer | No | Zero-based page index to request (sent as X-FM-Page header) |
| `type` | string ("Company" | "User" | "Offer" | "Product" | "Contact" | "Activity" | "Schedule") | Yes | Entity type to search for internal ID mapping. Use one of the predefined entity types: Company, User, Offer, Product, Contact, Activity, or Schedule. |
| `externalId` | string | Yes | External identifier of the entity in your system. Some API examples use 'externalid' (lowercase); this action sends both for compatibility. |
| `api_version` | integer | No | ForceManager API version to use (sent as X-FM-API-Version header) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Get Product

**Slug:** `FORCEMANAGER_GET_PRODUCT`

Retrieve a single product by its ID from ForceManager/Sage Sales Management. This action tries multiple known ForceManager API endpoints in sequence until one succeeds. If a product is not found or the API returns non-JSON content, it returns found=False with an empty entity dict. This graceful handling allows agents to check for product existence without encountering errors. Use this when you need to fetch product details such as name, price, cost, category, or custom fields by product ID.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | Identifier of the product to retrieve (positive integer) |
| `api_version` | integer | No | ForceManager API version to use (sent via X-FM-API-Version header) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Get Sales Order Line

**Slug:** `FORCEMANAGER_GET_SALES_ORDER_LINE`

Retrieves a single sales order line by ID from ForceManager. A sales order line represents a product item within a sales order, including quantity, pricing, and discount information. Use this when you need to fetch details about a specific line item in a sales order, such as product information, quantities, prices, or applied discounts.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | string | Yes | The unique identifier of the sales order line to retrieve (numeric string or integer) |
| `api_version` | integer | No | ForceManager API version to use (sent via X-FM-API-Version header). Optional, defaults to API's default version if not specified. |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Get User

**Slug:** `FORCEMANAGER_GET_USER`

Retrieves a single ForceManager user by their ID, returning comprehensive user information including name, email, phone, active status, permission level, manager, branches, and more. Returns the complete user object if found, or an empty entity with found=False if the user doesn't exist, was deleted, or the API returns an error. Automatically tries multiple ForceManager API endpoints and versions to ensure compatibility. Use this when you need to: fetch user profile details, verify user existence, check user permissions/status, or retrieve user contact information.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | string | Yes | User ID to retrieve. Can be a numeric string (e.g., '123') or alphanumeric identifier |
| `api_version` | integer | No | ForceManager API version to use (sent via X-FM-API-Version header). Defaults to version 4 if not specified |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Get View

**Slug:** `FORCEMANAGER_GET_VIEW`

Tool to get a single view by ID. Returns a list with zero or one view object.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | string | Yes | Unique identifier of the view to retrieve (numeric or alphanumeric string) |
| `api_version` | integer | No | ForceManager API version to use (sent via X-FM-API-Version header) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### List Views

**Slug:** `FORCEMANAGER_LIST_VIEWS`

Tool to list saved view filters. Use when you need to retrieve saved views for a specific entity (e.g., list views for entity 'account').

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `q` | string | No | Advanced search query (SQL-like) applied to views |
| `name` | string | No | Important-field LIKE filter to match view name |
| `page` | integer | No | Zero-based page index to request (sent as X-FM-Page header) |
| `entity` | string | No | Important-field LIKE filter to match target entity name |
| `api_version` | integer | No | ForceManager API version to use (sent as X-FM-API-Version header) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Update Activity

**Slug:** `FORCEMANAGER_UPDATE_ACTIVITY`

Tool to update an existing activity by ID. Use when you need to change fields such as comment, date/time, linked entities, or geocode.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | Activity identifier (positive integer) |
| `ext_id` | string | No | External id from third-party system |
| `comment` | string | No | Comments for the activity |
| `geocoded` | boolean | No | Calculated if geocode exists (read-only, discourage sending) |
| `account_id` | integer | No | Linked account id |
| `contact_id` | integer | No | Linked contact id |
| `is_checkin` | boolean | No | Whether this is a check-in (boolean, sent as 'True'/'False' per FM API) |
| `api_version` | integer | No | ForceManager API version to use (sent as X-FM-API-Version header) |
| `checkin_type` | string | No | If is_checkin=True: Standard Checkin \| Opportunity \| FastCheckin |
| `sales_rep_id` | integer | No | Sales rep ID (may be read-only) |
| `opportunity_id` | integer | No | Linked opportunity id |
| `activity_type_id` | integer | No | Activity type id |
| `geocode_accuracy` | number | No | Geocode accuracy |
| `geocode_latitude` | number | No | Latitude for check-ins |
| `permission_level` | integer | No | Permission level (1–5) |
| `geocode_longitude` | number | No | Longitude for check-ins |
| `activity_date_time` | string | No | UTC date and time of the activity in ISO 8601 format (YYYY-MM-DDThh:mm:ss) |
| `checkout_date_time` | string | No | Checkout date-time for check-out activities (ISO 8601 UTC) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Update Company

**Slug:** `FORCEMANAGER_UPDATE_COMPANY`

Update Company

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | Company identifier (positive integer). Must be an existing company ID from your ForceManager account. |
| `fax` | string | No | Fax number |
| `name` | string | No | Company name |
| `email` | string | No | Email address |
| `phone` | string | No | Primary phone number |
| `ext_id` | string | No | External system identifier for integration with other systems |
| `comment` | string | No | Comments or notes about the company |
| `phone_2` | string | No | Secondary phone number |
| `website` | string | No | Website URL |
| `postcode` | string | No | Postal/ZIP code |
| `address_1` | string | No | Primary address line |
| `address_2` | string | No | Secondary address line |
| `branch_id` | string | No | Branch identifier (string ID from ForceManager) |
| `city_name` | string | No | City name |
| `country_id` | string | No | Country identifier (numeric string or country code) |
| `segment_id` | string | No | Market segment identifier (string ID from ForceManager) |
| `vat_number` | string | No | VAT/tax identification number for the company |
| `api_version` | integer | No | ForceManager API version to use (sends X-FM-API-Version header) |
| `extra_fields` | object | No | Dictionary of extra custom fields (z_*) to merge into payload |
| `mobile_phone` | string | No | Mobile phone number |
| `sales_rep_id` | string | No | Primary sales representative user ID (string ID from ForceManager) |
| `province_name` | string | No | Province or state name |
| `sales_rep_2_id` | string | No | Secondary sales representative user ID |
| `sales_rep_3_id` | string | No | Third sales representative user ID |
| `sales_rep_4_id` | string | No | Fourth sales representative user ID |
| `sales_rep_5_id` | string | No | Fifth sales representative user ID |
| `visible_to_all` | boolean | No | Whether the company is visible to all users in the organization |
| `account_type_id` | string | No | Account type identifier (string ID from ForceManager) |
| `product_rate_id` | string | No | Default product rate/price list identifier |
| `permission_level` | integer | No | Access permission level (1=lowest to 5=highest) |
| `account_status_id` | string | No | Account status identifier (string ID from ForceManager) |
| `geolocalisation_accuracy` | string | No | Geolocation accuracy radius in meters (e.g., '50', '100') |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Update Product

**Slug:** `FORCEMANAGER_UPDATE_PRODUCT`

Updates an existing product by ID in ForceManager. Use this tool to modify product details such as name, price, cost, description, availability status, category, family, discount limits, and custom fields. The product must already exist - this action does not create new products. At least one field besides 'id' must be provided to update.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | Product identifier (positive integer) |
| `cost` | number | No | Manufacturing or acquisition cost (in currency units) |
| `model` | string | No | Product name or model identifier |
| `price` | number | No | Selling price (in currency units, e.g., 99.99) |
| `ext_id` | string | No | External ID from third-party system |
| `family_id` | integer | No | Product family ID for grouping related products |
| `api_version` | integer | No | ForceManager API version to use (sends X-FM-API-Version header) |
| `category_id` | integer | No | Category ID to classify the product |
| `description` | string | No | Product description or additional comment/notes |
| `extra_fields` | object | No | Dictionary of extra custom fields (z_*) to merge into payload |
| `max_discount` | number | No | Maximum allowed discount percentage (e.g., 15.5 for 15.5%) |
| `not_available` | boolean | No | Set to True to mark product as unavailable/out of stock, False to mark as available |
| `permission_level` | integer | No | Permission level (1–5) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Update Sales Order

**Slug:** `FORCEMANAGER_UPDATE_SALES_ORDER`

Update Sales Order

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | integer | Yes | Sales order identifier (positive integer) |
| `year` | integer | No | Order year |
| `topic` | string | No | Sales order topic |
| `amount` | number | No | Order amount, must be non-negative |
| `ext_id` | string | No | External identifier |
| `number` | integer | No | Order number |
| `address` | string | No | Address line for the order |
| `rate_id` | integer | No | Rate ID for the order |
| `archived` | boolean | No | Archive flag; True to archive |
| `comments` | string | No | Sales order comments |
| `branch_id` | integer | No | Branch ID |
| `status_id` | integer | No | Sales order status ID |
| `account_id` | integer | No | Linked account ID |
| `contact_id` | integer | No | Linked contact ID |
| `discount_1` | number | No | First discount value |
| `discount_2` | number | No | Second discount value |
| `discount_3` | number | No | Third discount value |
| `discount_4` | number | No | Fourth discount value |
| `api_version` | integer | No | ForceManager API version to use (sends X-FM-API-Version header) |
| `closed_date` | string | No | Actual closed date (YYYY-MM-DD) |
| `currency_id` | integer | No | Currency ID |
| `extra_fields` | object | No | Dictionary of extra custom fields (z_*) to merge into payload |
| `sales_rep_id` | integer | No | Sales representative ID |
| `opportunity_id` | integer | No | Linked opportunity ID |
| `closing_date_expected` | string | No | Expected closing date (YYYY-MM-DD) |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |

### Update Sales Order Line

**Slug:** `FORCEMANAGER_UPDATE_SALES_ORDER_LINE`

Tool to update sales order line by ID. Use when modifying details of an existing sales order line. Retries with query auth on 401 for proxy-pro host.

#### Input Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `id` | string | Yes | Identifier of the sales order line to update |
| `price` | number | No | Unit price before discounts, must be non-negative |
| `quantity` | integer | No | Quantity for this line, must be non-negative |
| `discount_1` | number | No | First discount, must be non-negative |
| `discount_2` | number | No | Second discount, must be non-negative |
| `discount_3` | number | No | Third discount, must be non-negative |
| `discount_4` | number | No | Fourth discount, must be non-negative |
| `product_id` | string | No | Identifier of the product for this line |
| `api_version` | integer | No | ForceManager API version to use (sends X-FM-API-Version header) |
| `final_price` | number | No | Final price after discounts, must be non-negative |
| `extra_fields` | object | No | Additional custom fields (e.g., z_customField) to merge into the payload |
| `salesorder_id` | string | No | Identifier of the sales order owning the line |

#### Output

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `data` | string | Yes | Data from the action execution |
| `error` | string | No | Error if any occurred during the execution of the action |
| `successful` | boolean | Yes | Whether or not the action execution was successful or not |
