# Update Subscription Updates an existing webhook subscription. All fields are optional. Endpoint: (PATCH) https://api.lusha.com/api/subscriptions/{id} --- Reactivating Disabled Subscriptions: When setting isActive: true on a previously disabled subscription, the system automatically: - Clears the blockReason field - Clears the blockedAt timestamp - Resets the retry counter Regenerating Secrets: Set regenerateSecret: true to generate a new webhook secret. The new secret: - Affects all subscriptions for your account - Is only shown once in the response - Immediately invalidates the old secret --- Endpoint: PATCH /api/subscriptions/{id} Security: ApiKeyAuth ## Path parameters: - `id` (string, required) Subscription ID Example: "507f1f77bcf86cd799439011" ## Request fields (application/json): - `signalTypes` (array) New signal types to subscribe to - `url` (string) New webhook URL - `name` (string) New subscription name - `isActive` (boolean) Enable or disable subscription - `regenerateSecret` (boolean) Generate new webhook secret (secret will be returned in response) ## Response 200 fields (application/json): - `id` (string) Subscription ID Example: "507f1f77bcf86cd799439011" - `entityType` (string) Enum: "contact", "company" - `entityId` (string) Example: "123456" - `signalTypes` (array) Example: ["promotion","companyChange"] - `url` (string) Example: "https://example.com/webhooks/lusha" - `name` (string) Example: "Contact Promotion Tracker" - `isActive` (boolean) Example: true - `secret` (string) Webhook secret for signature verification (only returned during creation or regeneration) Example: "whsec_abc123def456ghi789jkl012mno345pqr678stu901vwx234yz" - `createdAt` (string) Example: "2026-01-14T10:00:00.000Z" - `updatedAt` (string) Example: "2026-01-14T10:00:00.000Z" ## Response 400 fields (application/json): - `statusCode` (integer, required) HTTP status code Example: 400 - `message` (string, required) Error message Example: "Validation failed" - `errors` (array) Detailed error messages (optional, only for validation errors) Example: ["entityType must be one of: contact, company"] ## Response 404 fields (application/json): - `statusCode` (integer, required) HTTP status code Example: 400 - `message` (string, required) Error message Example: "Validation failed" - `errors` (array) Detailed error messages (optional, only for validation errors) Example: ["entityType must be one of: contact, company"] ## Response 500 fields (application/json): - `statusCode` (integer, required) HTTP status code Example: 400 - `message` (string, required) Error message Example: "Validation failed" - `errors` (array) Detailed error messages (optional, only for validation errors) Example: ["entityType must be one of: contact, company"]