Offers
Update an offer
Authorization
ApiKeyAuth X-API-Key<token>
API key generated from your Leadsail dashboard Settings page
In: header
Path Parameters
offerId*string
The offer ID
Request Body
application/json
name?string
Length
1 <= lengthabbrev?string
Length
1 <= length <= 10active?boolean
category?string
Value in
"mass_tort" | "personal_injury" | "class_action" | "employment" | "product_liability" | "medical_malpractice" | "workers_comp" | "other"description?string
eligibilityCriteria?array<>
tags?array<>
externalId?string
archivedAt?|
Response Body
application/json
application/json
application/json
application/json
package mainimport ( "fmt" "net/http" "io/ioutil" "strings")func main() { url := "https://api.leadsail.app/api/v1/offers/string" body := strings.NewReader(`{}`) req, _ := http.NewRequest("PATCH", url, body) req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := ioutil.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body))}{
"success": true,
"data": {
"offerId": "string",
"name": "string",
"abbrev": "string",
"active": true,
"category": "mass_tort",
"description": "string",
"eligibilityCriteria": [
"string"
],
"tags": [
"string"
],
"externalId": "string",
"createdAt": "string",
"updatedAt": "string",
"archivedAt": "string"
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "Invalid input data",
"details": [
"string"
]
}
}{
"success": false,
"error": {
"code": "UNAUTHORIZED",
"message": "Authentication required"
}
}{
"success": false,
"error": {
"code": "NOT_FOUND",
"message": "Resource not found"
}
}