{
  "service": "moco",
  "displayName": "MOCO",
  "categories": [
    "Productivity",
    "Finance"
  ],
  "authTypes": [
    "api_key"
  ],
  "auth": [
    {
      "type": "api_key",
      "label": "API Key",
      "placeholder": "MOCO_API_KEY",
      "description": "MOCO API key sent with Token authentication. Find a user API key under your profile Integrations tab, or create an account API key in Settings > Extensions > API & Webhooks: https://everii-group.github.io/mocoapp-api-docs/authentication.html.",
      "extraFields": [
        {
          "key": "account",
          "label": "Account",
          "inputType": "text",
          "required": true,
          "secret": false,
          "placeholder": "acme",
          "description": "Your MOCO account subdomain from https://{account}.mocoapp.com. You can enter either the subdomain or the full MOCO account URL."
        }
      ]
    }
  ],
  "homepageUrl": "https://www.mocoapp.com",
  "actions": [
    {
      "id": "moco.get_company",
      "service": "moco",
      "name": "get_company",
      "description": "Retrieve one MOCO company by ID.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "companyId": {
            "type": "integer",
            "minimum": 1,
            "description": "The MOCO company identifier."
          }
        },
        "additionalProperties": false,
        "description": "Path parameters for retrieving a MOCO company."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "company": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer",
                "minimum": 1,
                "description": "The MOCO company identifier."
              },
              "type": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The MOCO company type when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "name": {
                "type": "string",
                "description": "The MOCO company name."
              },
              "website": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The company website when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "email": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The company email address when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "phone": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The company phone number when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "tags": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "One MOCO tag."
                },
                "description": "MOCO tags attached to the record."
              },
              "identifier": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The MOCO company identifier string when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "active": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "Whether the company is active when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "archivedOn": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The company archive date when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "createdAt": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The company creation timestamp when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "updatedAt": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The company update timestamp when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "raw": {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw MOCO record returned by the API."
              }
            },
            "additionalProperties": false,
            "description": "A normalized MOCO company."
          }
        },
        "additionalProperties": false,
        "description": "The normalized MOCO company response."
      }
    },
    {
      "id": "moco.get_contact",
      "service": "moco",
      "name": "get_contact",
      "description": "Retrieve one MOCO contact person by ID.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "contactId": {
            "type": "integer",
            "minimum": 1,
            "description": "The MOCO contact identifier."
          }
        },
        "additionalProperties": false,
        "description": "Path parameters for retrieving a MOCO contact person."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "contact": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer",
                "minimum": 1,
                "description": "The MOCO contact identifier."
              },
              "gender": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact gender code when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "firstName": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact first name when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "lastName": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact last name when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "fullName": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact full name assembled from returned name fields."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "jobPosition": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact job position when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "mobilePhone": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact mobile phone number when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "workPhone": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact work phone number when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "workEmail": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact work email address when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "tags": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "One MOCO tag."
                },
                "description": "MOCO tags attached to the record."
              },
              "company": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "integer",
                        "minimum": 1,
                        "description": "The MOCO company identifier."
                      },
                      "type": {
                        "anyOf": [
                          {
                            "type": "string",
                            "description": "The MOCO company type when returned."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "name": {
                        "type": "string",
                        "description": "The MOCO company name."
                      }
                    },
                    "additionalProperties": false,
                    "description": "A compact MOCO company reference."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "createdAt": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact creation timestamp when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "updatedAt": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The contact update timestamp when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "raw": {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw MOCO record returned by the API."
              }
            },
            "additionalProperties": false,
            "description": "A normalized MOCO contact person."
          }
        },
        "additionalProperties": false,
        "description": "The normalized MOCO contact response."
      }
    },
    {
      "id": "moco.get_profile",
      "service": "moco",
      "name": "get_profile",
      "description": "Retrieve the current MOCO user's profile.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false,
        "description": "No input is required for retrieving the current MOCO profile."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "profile": {
            "type": "object",
            "properties": {
              "id": {
                "type": "integer",
                "minimum": 1,
                "description": "The MOCO profile user identifier."
              },
              "email": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The profile email address when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "fullName": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The profile full name when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "firstName": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The profile first name when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "lastName": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The profile last name when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "active": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "Whether the profile user is active when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "external": {
                "anyOf": [
                  {
                    "type": "boolean",
                    "description": "Whether the profile user is external when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "avatarUrl": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The profile avatar URL when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "unit": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "integer",
                        "minimum": 1,
                        "description": "The MOCO unit identifier."
                      },
                      "name": {
                        "type": "string",
                        "description": "The MOCO unit name."
                      }
                    },
                    "additionalProperties": false,
                    "description": "A compact MOCO unit reference."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "createdAt": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The profile creation timestamp when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "updatedAt": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The profile update timestamp when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "raw": {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw MOCO record returned by the API."
              }
            },
            "additionalProperties": false,
            "description": "A normalized MOCO profile."
          }
        },
        "additionalProperties": false,
        "description": "The normalized MOCO profile response."
      }
    },
    {
      "id": "moco.list_companies",
      "service": "moco",
      "name": "list_companies",
      "description": "List MOCO companies with official filters and response-header pagination.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "page": {
            "type": "integer",
            "minimum": 1,
            "description": "The MOCO page number to request."
          },
          "perPage": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "description": "The number of MOCO records to request per page."
          },
          "updatedAfter": {
            "type": "string",
            "description": "Return records updated after this UTC timestamp.",
            "format": "date-time"
          },
          "sortBy": {
            "type": "string",
            "minLength": 1,
            "description": "The MOCO field name to sort by."
          },
          "sortDirection": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "description": "The MOCO sort direction."
          },
          "includeArchived": {
            "type": "boolean",
            "description": "Whether archived MOCO companies should be included."
          },
          "type": {
            "type": "string",
            "enum": [
              "customer",
              "supplier",
              "organization"
            ],
            "description": "The MOCO company type."
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "One tag."
            },
            "description": "Tags to match as a comma-separated MOCO tags filter.",
            "minItems": 1
          },
          "identifier": {
            "type": "string",
            "minLength": 1,
            "description": "Filter companies by the MOCO identifier string."
          },
          "term": {
            "type": "string",
            "minLength": 1,
            "description": "Search companies by term."
          }
        },
        "additionalProperties": false,
        "description": "Query parameters for listing MOCO companies."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "companies": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer",
                  "minimum": 1,
                  "description": "The MOCO company identifier."
                },
                "type": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The MOCO company type when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "name": {
                  "type": "string",
                  "description": "The MOCO company name."
                },
                "website": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The company website when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "email": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The company email address when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "phone": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The company phone number when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "tags": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "description": "One MOCO tag."
                  },
                  "description": "MOCO tags attached to the record."
                },
                "identifier": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The MOCO company identifier string when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "active": {
                  "anyOf": [
                    {
                      "type": "boolean",
                      "description": "Whether the company is active when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "archivedOn": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The company archive date when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "createdAt": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The company creation timestamp when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "updatedAt": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The company update timestamp when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw MOCO record returned by the API."
                }
              },
              "additionalProperties": false,
              "description": "A normalized MOCO company."
            },
            "description": "Companies returned by MOCO."
          },
          "pagination": {
            "type": "object",
            "properties": {
              "page": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The current MOCO response page when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "perPage": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The page size returned by MOCO when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "total": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The total number of matching records when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "hasNextPage": {
                "type": "boolean",
                "description": "Whether the MOCO Link header contains a next page."
              },
              "nextPage": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The next page number when MOCO returned one."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "description": "Pagination metadata normalized from MOCO response headers."
          }
        },
        "additionalProperties": false,
        "description": "The normalized MOCO company list response."
      }
    },
    {
      "id": "moco.list_contacts",
      "service": "moco",
      "name": "list_contacts",
      "description": "List MOCO contact people with official filters and response-header pagination.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "page": {
            "type": "integer",
            "minimum": 1,
            "description": "The MOCO page number to request."
          },
          "perPage": {
            "type": "integer",
            "minimum": 1,
            "maximum": 100,
            "description": "The number of MOCO records to request per page."
          },
          "updatedAfter": {
            "type": "string",
            "description": "Return records updated after this UTC timestamp.",
            "format": "date-time"
          },
          "sortBy": {
            "type": "string",
            "minLength": 1,
            "description": "The MOCO field name to sort by."
          },
          "sortDirection": {
            "type": "string",
            "enum": [
              "asc",
              "desc"
            ],
            "description": "The MOCO sort direction."
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "One tag."
            },
            "description": "Tags to match as a comma-separated MOCO tags filter.",
            "minItems": 1
          },
          "term": {
            "type": "string",
            "minLength": 1,
            "description": "Search contacts by name, email, or company."
          },
          "phone": {
            "type": "string",
            "minLength": 1,
            "description": "Reverse lookup contacts by work or mobile phone number."
          }
        },
        "additionalProperties": false,
        "description": "Query parameters for listing MOCO contact people."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "contacts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "integer",
                  "minimum": 1,
                  "description": "The MOCO contact identifier."
                },
                "gender": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact gender code when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "firstName": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact first name when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "lastName": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact last name when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "fullName": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact full name assembled from returned name fields."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "jobPosition": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact job position when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "mobilePhone": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact mobile phone number when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "workPhone": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact work phone number when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "workEmail": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact work email address when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "tags": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "description": "One MOCO tag."
                  },
                  "description": "MOCO tags attached to the record."
                },
                "company": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer",
                          "minimum": 1,
                          "description": "The MOCO company identifier."
                        },
                        "type": {
                          "anyOf": [
                            {
                              "type": "string",
                              "description": "The MOCO company type when returned."
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "name": {
                          "type": "string",
                          "description": "The MOCO company name."
                        }
                      },
                      "additionalProperties": false,
                      "description": "A compact MOCO company reference."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "createdAt": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact creation timestamp when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "updatedAt": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact update timestamp when returned."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw MOCO record returned by the API."
                }
              },
              "additionalProperties": false,
              "description": "A normalized MOCO contact person."
            },
            "description": "Contacts returned by MOCO."
          },
          "pagination": {
            "type": "object",
            "properties": {
              "page": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The current MOCO response page when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "perPage": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The page size returned by MOCO when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "total": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The total number of matching records when returned."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "hasNextPage": {
                "type": "boolean",
                "description": "Whether the MOCO Link header contains a next page."
              },
              "nextPage": {
                "anyOf": [
                  {
                    "type": "integer",
                    "description": "The next page number when MOCO returned one."
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "additionalProperties": false,
            "description": "Pagination metadata normalized from MOCO response headers."
          }
        },
        "additionalProperties": false,
        "description": "The normalized MOCO contact list response."
      }
    }
  ]
}
