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

# Unlink Activities from an Opportunity

> Unlinks activities from an opportunity and blocks automatic relinking, even if no link exists yet. Email ids are per-mailbox Gmail thread ids; identical mailbox copies are unlinked too.



## OpenAPI

````yaml https://api.monaco.com/openapi.json post /v1/opportunities/{opportunity_id}/activities/remove
openapi: 3.2.1
info:
  title: Monaco Public API
  description: Public API for Monaco
  version: 1.0.0
servers:
  - url: https://api.monaco.com
security: []
paths:
  /v1/opportunities/{opportunity_id}/activities/remove:
    post:
      tags:
        - Opportunities
      summary: Unlink Activities from an Opportunity
      description: >-
        Unlinks activities from an opportunity and blocks automatic relinking,
        even if no link exists yet. Email ids are per-mailbox Gmail thread ids;
        identical mailbox copies are unlinked too.
      operationId: unlink_activity_to_opportunity
      parameters:
        - name: opportunity_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Opportunity Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ActivityOpportunityLinksRequest'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/PublicItemResponse_list_ActivityOpportunityLinkRequest__
        4XX:
          description: Client error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicErrorResponse'
components:
  schemas:
    ActivityOpportunityLinksRequest:
      properties:
        activities:
          items:
            $ref: '#/components/schemas/ActivityOpportunityLinkRequest'
          type: array
          maxItems: 100
          minItems: 1
          title: Activities
      additionalProperties: false
      type: object
      required:
        - activities
      title: ActivityOpportunityLinksRequest
    PublicItemResponse_list_ActivityOpportunityLinkRequest__:
      properties:
        data:
          items:
            $ref: '#/components/schemas/ActivityOpportunityLinkRequest'
          type: array
          title: Data
        meta:
          $ref: '#/components/schemas/ResponseMeta'
      type: object
      required:
        - data
      title: PublicItemResponse[list[ActivityOpportunityLinkRequest]]
    PublicErrorResponse:
      properties:
        error:
          $ref: '#/components/schemas/ErrorDetail'
      type: object
      required:
        - error
      title: PublicErrorResponse
    ActivityOpportunityLinkRequest:
      properties:
        channel:
          $ref: '#/components/schemas/ActivityChannel'
        activity_id:
          type: string
          minLength: 1
          title: Activity Id
          description: >-
            Activity id within its channel. Email ids are per-mailbox Gmail
            thread ids.
      additionalProperties: false
      type: object
      required:
        - channel
        - activity_id
      title: ActivityOpportunityLinkRequest
    ResponseMeta:
      properties:
        timestamp:
          type: string
          format: date-time
          title: Timestamp
          description: Server timestamp of the response
      type: object
      title: ResponseMeta
    ErrorDetail:
      properties:
        code:
          type: string
          title: Code
          description: Machine-readable error code
          examples:
            - not_found
        message:
          type: string
          title: Message
          description: Human-readable error message
          examples:
            - Resource not found
        data:
          anyOf:
            - additionalProperties:
                anyOf:
                  - type: string
                  - type: integer
              type: object
            - type: 'null'
          title: Data
          description: >-
            Details for some codes: `field_too_long` carries `field`, `limit`
            and `actual`, plus `unit` (`items` or `bytes`) when the limit isn't
            in characters; `too_many_custom_fields` carries `entity_type` and
            `limit`
      type: object
      required:
        - code
        - message
      title: ErrorDetail
    ActivityChannel:
      type: string
      enum:
        - email
        - meeting
        - linkedin
        - slack
      title: ActivityChannel
      description: Channel of an activity the activity-opportunity linker evaluates.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.