{
  "service": "chartmogul",
  "displayName": "ChartMogul",
  "categories": [
    "Finance",
    "Data"
  ],
  "authTypes": [
    "api_key"
  ],
  "auth": [
    {
      "type": "api_key",
      "label": "API Key",
      "placeholder": "CHARTMOGUL_API_KEY",
      "description": "ChartMogul API key used as the HTTP Basic Auth username with an empty password. Create or view API keys from Profile > View Profile > API Keys: https://help.chartmogul.com/article/95-creating-and-managing-api-keys."
    }
  ],
  "homepageUrl": "https://chartmogul.com/",
  "actions": [
    {
      "id": "chartmogul.get_account",
      "service": "chartmogul",
      "name": "get_account",
      "description": "Retrieve basic ChartMogul account settings for the authenticated API key.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "include": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "churn_recognition",
                "churn_when_zero_mrr",
                "auto_churn_subscription",
                "refund_handling",
                "proximate_movement_reclassification"
              ],
              "description": "One supported ChartMogul account setting include value."
            },
            "description": "Additional account settings to include in the response.",
            "minItems": 1
          }
        },
        "additionalProperties": false,
        "description": "Input parameters for retrieving ChartMogul account settings."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "account": {
            "type": "object",
            "properties": {
              "uuid": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The ChartMogul account UUID."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "name": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The account name returned by ChartMogul."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "currency": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The account ISO 4217 currency code."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "timeZone": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The account time zone identifier."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "weekStartOn": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The first day of the week configured for the account."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "raw": {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw account object returned by ChartMogul."
              }
            },
            "additionalProperties": false,
            "description": "A normalized ChartMogul account object."
          }
        },
        "additionalProperties": false,
        "description": "The response returned when retrieving ChartMogul account details."
      }
    },
    {
      "id": "chartmogul.get_customer",
      "service": "chartmogul",
      "name": "get_customer",
      "description": "Retrieve a single ChartMogul customer by customer UUID.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "customerUuid": {
            "type": "string",
            "minLength": 1,
            "description": "The ChartMogul UUID of the customer."
          }
        },
        "additionalProperties": false,
        "description": "Input parameters for retrieving a ChartMogul customer."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "customer": {
            "type": "object",
            "properties": {
              "uuid": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The ChartMogul UUID for the customer."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "externalId": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The primary external customer identifier."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "externalIds": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "One external customer identifier."
                },
                "description": "All external customer identifiers returned by ChartMogul."
              },
              "dataSourceUuid": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The source UUID for the customer."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "dataSourceUuids": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "One source UUID."
                },
                "description": "All source UUIDs associated with the customer."
              },
              "name": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The customer name when returned by ChartMogul."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "email": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The customer email when returned by ChartMogul."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "status": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The combined lead or subscription status."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "company": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The customer company name."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "country": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The customer country code."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "state": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The customer state or region."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "city": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The customer city."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "customerSince": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The time when the customer first became a customer."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "mrr": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "The current monthly recurring revenue in the account currency subunit."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "arr": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "The current annual recurring revenue in the account currency subunit."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "currency": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The customer currency code."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "chartmogulUrl": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The ChartMogul app URL for the customer."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "billingSystemUrl": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "The upstream billing system URL for the customer."
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "raw": {
                "type": "object",
                "properties": {},
                "additionalProperties": true,
                "description": "The raw customer object returned by ChartMogul."
              }
            },
            "additionalProperties": false,
            "description": "A normalized ChartMogul customer."
          }
        },
        "additionalProperties": false,
        "description": "The response returned when retrieving a ChartMogul customer."
      }
    },
    {
      "id": "chartmogul.list_contacts",
      "service": "chartmogul",
      "name": "list_contacts",
      "description": "List ChartMogul contacts with cursor pagination and common contact filters.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "email": {
            "type": "string",
            "minLength": 1,
            "description": "The contact email address to filter by."
          },
          "customerExternalId": {
            "type": "string",
            "minLength": 1,
            "description": "The customer external identifier whose contacts should be returned."
          },
          "customerUuid": {
            "type": "string",
            "minLength": 1,
            "description": "The ChartMogul UUID of the customer."
          },
          "dataSourceUuid": {
            "type": "string",
            "minLength": 1,
            "description": "The source UUID whose contacts should be returned."
          },
          "cursor": {
            "type": "string",
            "minLength": 1,
            "description": "The cursor returned by ChartMogul for fetching the next page."
          },
          "perPage": {
            "type": "integer",
            "minimum": 1,
            "maximum": 200,
            "description": "The maximum number of records to return. ChartMogul caps this at 200."
          }
        },
        "additionalProperties": false,
        "description": "Input parameters for listing ChartMogul contacts."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "contacts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "uuid": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The ChartMogul UUID for the contact."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "customerUuid": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The ChartMogul UUID of the owning customer."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "customerExternalId": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The external ID of the owning customer."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "dataSourceUuid": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The source UUID for the contact."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "externalId": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The external contact identifier."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "firstName": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact first name."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "lastName": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact last name."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "title": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact job title."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "email": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact email address."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "phone": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact phone number."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "linkedIn": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact LinkedIn URL."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "twitter": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The contact Twitter or X URL."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "position": {
                  "anyOf": [
                    {
                      "type": "integer",
                      "description": "The contact position value returned by ChartMogul."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw contact object returned by ChartMogul."
                }
              },
              "additionalProperties": false,
              "description": "A normalized ChartMogul contact."
            },
            "description": "The contacts returned by ChartMogul."
          },
          "cursor": {
            "anyOf": [
              {
                "type": "string",
                "description": "The cursor to use for the next page when ChartMogul returns one."
              },
              {
                "type": "null"
              }
            ]
          },
          "hasMore": {
            "type": "boolean",
            "description": "Whether ChartMogul reports more records after this page."
          }
        },
        "additionalProperties": false,
        "description": "The response returned when listing ChartMogul contacts."
      }
    },
    {
      "id": "chartmogul.list_customers",
      "service": "chartmogul",
      "name": "list_customers",
      "description": "List ChartMogul customers with cursor pagination and common customer filters.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "dataSourceUuid": {
            "type": "string",
            "minLength": 1,
            "description": "The ChartMogul source UUID used to filter customers."
          },
          "externalId": {
            "type": "string",
            "minLength": 1,
            "description": "The external customer identifier to filter by."
          },
          "email": {
            "type": "string",
            "minLength": 1,
            "description": "The customer email address to search for."
          },
          "withAssociatedEmails": {
            "type": "boolean",
            "description": "Whether email search should also match associated contact email addresses."
          },
          "status": {
            "type": "string",
            "minLength": 1,
            "description": "The lead or subscription status to filter by."
          },
          "system": {
            "type": "string",
            "minLength": 1,
            "description": "The billing system to filter by, such as Stripe, Recurly, or Custom."
          },
          "cursor": {
            "type": "string",
            "minLength": 1,
            "description": "The cursor returned by ChartMogul for fetching the next page."
          },
          "perPage": {
            "type": "integer",
            "minimum": 1,
            "maximum": 200,
            "description": "The maximum number of records to return. ChartMogul caps this at 200."
          }
        },
        "additionalProperties": false,
        "description": "Input parameters for listing ChartMogul customers."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "customers": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "uuid": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The ChartMogul UUID for the customer."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "externalId": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The primary external customer identifier."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "externalIds": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "description": "One external customer identifier."
                  },
                  "description": "All external customer identifiers returned by ChartMogul."
                },
                "dataSourceUuid": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The source UUID for the customer."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "dataSourceUuids": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "description": "One source UUID."
                  },
                  "description": "All source UUIDs associated with the customer."
                },
                "name": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The customer name when returned by ChartMogul."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "email": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The customer email when returned by ChartMogul."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "status": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The combined lead or subscription status."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "company": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The customer company name."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "country": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The customer country code."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "state": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The customer state or region."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "city": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The customer city."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "customerSince": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The time when the customer first became a customer."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "mrr": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The current monthly recurring revenue in the account currency subunit."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "arr": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The current annual recurring revenue in the account currency subunit."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "currency": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The customer currency code."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "chartmogulUrl": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The ChartMogul app URL for the customer."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "billingSystemUrl": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The upstream billing system URL for the customer."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw customer object returned by ChartMogul."
                }
              },
              "additionalProperties": false,
              "description": "A normalized ChartMogul customer."
            },
            "description": "The customers returned by ChartMogul."
          },
          "cursor": {
            "anyOf": [
              {
                "type": "string",
                "description": "The cursor to use for the next page when ChartMogul returns one."
              },
              {
                "type": "null"
              }
            ]
          },
          "hasMore": {
            "type": "boolean",
            "description": "Whether ChartMogul reports more records after this page."
          }
        },
        "additionalProperties": false,
        "description": "The response returned when listing ChartMogul customers."
      }
    },
    {
      "id": "chartmogul.list_sources",
      "service": "chartmogul",
      "name": "list_sources",
      "description": "List ChartMogul data sources with optional source name or billing system filters.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "description": "The source name to filter by."
          },
          "system": {
            "type": "string",
            "minLength": 1,
            "description": "The billing system type to filter by, such as Stripe, Recurly, or Custom."
          }
        },
        "additionalProperties": false,
        "description": "Input parameters for listing ChartMogul data sources."
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "dataSources": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "uuid": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The ChartMogul UUID for the source."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "name": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The source name."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "system": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The billing system type for the source."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "createdAt": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The time when the source was created."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "status": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The current source status."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw data source object returned by ChartMogul."
                }
              },
              "additionalProperties": false,
              "description": "A normalized ChartMogul data source."
            },
            "description": "The data sources returned by ChartMogul."
          }
        },
        "additionalProperties": false,
        "description": "The response returned when listing ChartMogul data sources."
      }
    }
  ]
}
