(Incidents)
Operations related to Incidents
- GetAiSummaryVoteStatus - Get the vote status for an AI-generated incident summary
- List - List incidents
- Create - Create an incident
- Get - Get an incident
- Archive - Archive an incident
- Update - Update an incident
- DeleteAlert - Delete an alert from an incident
- SetAlertAsPrimary - Set an alert as primary for an incident
- ListAttachments - List attachments for an incident
- CreateAttachment - Create an attachment for an incident
- GetChannel - Get chat channel information for an incident
- Close - Close an incident
- ListEvents - List events for an incident
- GetEvent - Get an incident event
- DeleteEvent - Delete an incident event
- UpdateEvent - Update an incident event
- UpdateEventVotes - Update votes for an incident event
- GetEventVoteStatus - Get vote counts for an incident event
- CreateGenericChatMessage - Create a chat message for an incident
- DeleteChatMessage - Delete a chat message from an incident
- UpdateChatMessage - Update a chat message in an incident
- UpdateImpacts - Replace all impacts for an incident
- PartialUpdateImpacts - Update impacts for an incident
- ListImpact - List impacted infrastructure for an incident
- CreateImpact - Add impacted infrastructure to an incident
- DeleteImpact - Remove impacted infrastructure from an incident
- ListLinks - List links for an incident
- CreateLink - Create a link for an incident
- UpdateLink - Update an external link for an incident
- DeleteLink - Delete an external link from an incident
- ListMilestones - List milestones for an incident
- UpdateMilestonesBulk - Bulk update milestone timestamps for an incident
- CreateNote - Create a note for an incident
- UpdateNote - Update a note for an incident
- ListRelatedChangeEvents - List related changes for an incident
- CreateRelatedChange - Add a related change to an incident
- UpdateRelatedChangeEvent - Update a related change event for an incident
- GetRelationships - List incident relationships
- Resolve - Resolve an incident
- ListRoleAssignments - List role assignments for an incident
- CreateRoleAssignment - Create a role assignment for an incident
- DeleteRoleAssignment - Delete a role assignment from an incident
- ListSimilar - List similar incidents
- ListStatusPages - List status pages for an incident
- AddStatusPage - Add a status page to an incident
- CreateTaskList - Add tasks from a task list to an incident
- CreateTeamAssignment - Assign a team to an incident
- DeleteTeamAssignment - Remove a team assignment from an incident
- GetTranscript - List transcript messages for an incident
- DeleteTranscript - Delete a transcript from an incident
- Unarchive - Unarchive an incident
- GetUserRole - Get a user's role in an incident
Get the vote status for an AI-generated incident summary
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.GetAiSummaryVoteStatus(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
generatedSummaryID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.GetIncidentAiSummaryVoteStatusResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List all of the incidents in the organization
package main
import(
"firehydrant"
"context"
"firehydrant/models/operations"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.List(ctx, operations.ListIncidentsRequest{})
if err != nil {
log.Fatal(err)
}
if res.IncidentEntityPaginated != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
request |
operations.ListIncidentsRequest | ✔️ | The request object to use for the request. |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ListIncidentsResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Create a new incident
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.Create(ctx, components.PostV1Incidents{
Name: "<value>",
})
if err != nil {
log.Fatal(err)
}
if res.IncidentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
request |
components.PostV1Incidents | ✔️ | The request object to use for the request. |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Retrieve a single incident from its ID
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.Get(ctx, "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.GetIncidentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Archives an incident which will hide it from lists and metrics
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.Archive(ctx, "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ArchiveIncidentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Updates an incident with provided parameters
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.Update(ctx, "<id>", components.PatchV1IncidentsIncidentID{})
if err != nil {
log.Fatal(err)
}
if res.IncidentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
patchV1IncidentsIncidentID |
components.PatchV1IncidentsIncidentID | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UpdateIncidentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Remove an alert from an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.DeleteAlert(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentAlertID |
string | ✔️ | N/A |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.DeleteIncidentAlertResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Setting an alert as primary will overwrite milestone times in the FireHydrant incident with times included in the primary alert. Services attached to the primary alert will also be automatically added to the incident.
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.SetAlertAsPrimary(ctx, "<id>", "<id>", components.PatchV1IncidentsIncidentIDAlertsIncidentAlertIDPrimary{
Primary: false,
})
if err != nil {
log.Fatal(err)
}
if res.IncidentsAlertEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentAlertID |
string | ✔️ | N/A |
incidentID |
string | ✔️ | N/A |
patchV1IncidentsIncidentIDAlertsIncidentAlertIDPrimary |
components.PatchV1IncidentsIncidentIDAlertsIncidentAlertIDPrimary | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.SetIncidentAlertAsPrimaryResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List attachments for an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.ListAttachments(ctx, "<id>", nil, nil, nil)
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
attachableType |
*string | ➖ | N/A |
page |
*int | ➖ | N/A |
perPage |
*int | ➖ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ListIncidentAttachmentsResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Allows adding image attachments to an incident
package main
import(
"firehydrant"
"os"
"context"
"firehydrant/models/operations"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
content, fileErr := os.Open("example.file")
if fileErr != nil {
panic(fileErr)
}
ctx := context.Background()
res, err := s.Incidents.CreateAttachment(ctx, "<id>", operations.CreateIncidentAttachmentRequestBody{
File: operations.File{
FileName: "example.file",
Content: content,
},
})
if err != nil {
log.Fatal(err)
}
if res.IncidentAttachmentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
requestBody |
operations.CreateIncidentAttachmentRequestBody | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentAttachmentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Gives chat channel information for the specified incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.GetChannel(ctx, "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentsChannelEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.GetIncidentChannelResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Closes an incident and optionally close all children
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.Close(ctx, "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CloseIncidentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List all events for an incident. An event is a timeline entry. This can be filtered with params to retrieve events of a certain type.
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.ListEvents(ctx, "<id>", nil, nil, nil)
if err != nil {
log.Fatal(err)
}
if res.IncidentEventEntityPaginated != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
types |
*string | ➖ | A comma separated list of types of events to filter by |
page |
*int | ➖ | N/A |
perPage |
*int | ➖ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ListIncidentEventsResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Retrieve a single event for an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.GetEvent(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentEventEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
eventID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.GetIncidentEventResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Delete a single event for an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.DeleteEvent(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentEventEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
eventID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.DeleteIncidentEventResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Update a single event for an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.UpdateEvent(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentEventEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
eventID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UpdateIncidentEventResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Allows for upvoting or downvoting an event
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.UpdateEventVotes(ctx, "<id>", "<id>", components.PatchV1IncidentsIncidentIDEventsEventIDVotes{
Direction: components.DirectionDig,
})
if err != nil {
log.Fatal(err)
}
if res.VotesEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
eventID |
string | ✔️ | N/A |
patchV1IncidentsIncidentIDEventsEventIDVotes |
components.PatchV1IncidentsIncidentIDEventsEventIDVotes | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UpdateIncidentEventVotesResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Returns the current vote counts for an object
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.GetEventVoteStatus(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res.VotesEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
eventID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.GetIncidentEventVoteStatusResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Create a new generic chat message on an incident timeline. These are independent of any specific chat provider.
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.CreateGenericChatMessage(ctx, "<id>", components.PostV1IncidentsIncidentIDGenericChatMessages{
Body: "<value>",
})
if err != nil {
log.Fatal(err)
}
if res.EventGenericChatMessageEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
postV1IncidentsIncidentIDGenericChatMessages |
components.PostV1IncidentsIncidentIDGenericChatMessages | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentGenericChatMessageResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Delete an existing generic chat message on an incident.
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.DeleteChatMessage(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res.EventGenericChatMessageEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
messageID |
string | ✔️ | N/A |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.DeleteIncidentChatMessageResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Update an existing generic chat message on an incident.
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.UpdateChatMessage(ctx, "<id>", "<id>", components.PatchV1IncidentsIncidentIDGenericChatMessagesMessageID{
Body: "<value>",
})
if err != nil {
log.Fatal(err)
}
if res.EventGenericChatMessageEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
messageID |
string | ✔️ | N/A |
incidentID |
string | ✔️ | N/A |
patchV1IncidentsIncidentIDGenericChatMessagesMessageID |
components.PatchV1IncidentsIncidentIDGenericChatMessagesMessageID | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UpdateIncidentChatMessageResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Allows updating an incident's impacted infrastructure, with the option to move the incident into a different milestone and provide a note to update the incident timeline and any attached status pages. If this method is requested with the PUT verb, impacts will be completely replaced with the information in the request body, even if not provided (effectively clearing all impacts). If this method is requested with the PATCH verb, the provided impacts will be added or updated, but no impacts will be removed.
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.UpdateImpacts(ctx, "<id>", components.PutV1IncidentsIncidentIDImpact{})
if err != nil {
log.Fatal(err)
}
if res.IncidentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
putV1IncidentsIncidentIDImpact |
components.PutV1IncidentsIncidentIDImpact | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UpdateIncidentImpactsResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Allows updating an incident's impacted infrastructure, with the option to move the incident into a different milestone and provide a note to update the incident timeline and any attached status pages. If this method is requested with the PUT verb, impacts will be completely replaced with the information in the request body, even if not provided (effectively clearing all impacts). If this method is requested with the PATCH verb, the provided impacts will be added or updated, but no impacts will be removed.
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.PartialUpdateImpacts(ctx, "<id>", components.PatchV1IncidentsIncidentIDImpact{})
if err != nil {
log.Fatal(err)
}
if res.IncidentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
patchV1IncidentsIncidentIDImpact |
components.PatchV1IncidentsIncidentIDImpact | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.PartialUpdateIncidentImpactsResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List impacted infrastructure on an incident by specifying type
package main
import(
"firehydrant"
"context"
"firehydrant/models/operations"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.ListImpact(ctx, "<id>", operations.PathParamTypeEnvironments)
if err != nil {
log.Fatal(err)
}
if res.IncidentImpactEntityPaginated != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
type_ |
operations.PathParamType | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ListIncidentImpactResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Add impacted infrastructure to an incident
package main
import(
"firehydrant"
"context"
"firehydrant/models/operations"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.CreateImpact(ctx, "<id>", operations.CreateIncidentImpactPathParamTypeServices, components.PostV1IncidentsIncidentIDImpactType{
ID: "<id>",
})
if err != nil {
log.Fatal(err)
}
if res.IncidentImpactEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
type_ |
operations.CreateIncidentImpactPathParamType | ✔️ | N/A |
postV1IncidentsIncidentIDImpactType |
components.PostV1IncidentsIncidentIDImpactType | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentImpactResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.ErrorEntity | 400 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.BadRequest | 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Remove impacted infrastructure on an incident
package main
import(
"firehydrant"
"context"
"firehydrant/models/operations"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.DeleteImpact(ctx, "<id>", operations.DeleteIncidentImpactPathParamTypeServices, "<id>")
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
type_ |
operations.DeleteIncidentImpactPathParamType | ✔️ | N/A |
id |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.DeleteIncidentImpactResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.ErrorEntity | 400 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.BadRequest | 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List all the editable, external incident links attached to an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.ListLinks(ctx, "<id>", nil, nil)
if err != nil {
log.Fatal(err)
}
if res.AttachmentsLinkEntityPaginated != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
page |
*int | ➖ | N/A |
perPage |
*int | ➖ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ListIncidentLinksResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Allows adding adhoc links to an incident as an attachment
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.CreateLink(ctx, "<id>", components.PostV1IncidentsIncidentIDLinks{
Href: "<value>",
})
if err != nil {
log.Fatal(err)
}
if res.AttachmentsLinkEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
postV1IncidentsIncidentIDLinks |
components.PostV1IncidentsIncidentIDLinks | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentLinkResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Updates the external incident link attributes
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.UpdateLink(ctx, "<id>", "<id>", components.PutV1IncidentsIncidentIDLinksLinkID{})
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
linkID |
string | ✔️ | N/A |
incidentID |
string | ✔️ | N/A |
putV1IncidentsIncidentIDLinksLinkID |
components.PutV1IncidentsIncidentIDLinksLinkID | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UpdateIncidentLinkResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Deletes the external incident link
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.DeleteLink(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
linkID |
string | ✔️ | N/A |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.DeleteIncidentLinkResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List times and durations for each milestone on an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.ListMilestones(ctx, "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentsMilestoneEntityPaginated != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ListIncidentMilestonesResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Update milestone times in bulk for a given incident. All milestone times for an incident must occur in chronological order corresponding to the configured order of milestones. If the result of this request would cause any milestone(s) to appear out of place, a 422 response will instead be returned. This includes milestones not explicitly submitted or updated in this request.
package main
import(
"firehydrant"
"context"
"firehydrant/types"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.UpdateMilestonesBulk(ctx, "<id>", components.PutV1IncidentsIncidentIDMilestonesBulkUpdate{
Milestones: []components.PutV1IncidentsIncidentIDMilestonesBulkUpdateMilestones{
components.PutV1IncidentsIncidentIDMilestonesBulkUpdateMilestones{
Type: "<value>",
OccurredAt: types.MustTimeFromString("2023-05-22T05:39:43.411Z"),
},
},
})
if err != nil {
log.Fatal(err)
}
if res.IncidentsMilestoneEntityPaginated != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
putV1IncidentsIncidentIDMilestonesBulkUpdate |
components.PutV1IncidentsIncidentIDMilestonesBulkUpdate | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UpdateIncidentMilestonesBulkResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Create a new note on for an incident. The visibility field on a note determines where it gets posted.
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.CreateNote(ctx, "<id>", components.PostV1IncidentsIncidentIDNotes{
Body: "<value>",
})
if err != nil {
log.Fatal(err)
}
if res.EventNoteEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
postV1IncidentsIncidentIDNotes |
components.PostV1IncidentsIncidentIDNotes | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentNoteResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Updates the body of a note
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.UpdateNote(ctx, "<id>", "<id>", components.PatchV1IncidentsIncidentIDNotesNoteID{
Body: "<value>",
})
if err != nil {
log.Fatal(err)
}
if res.EventNoteEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
noteID |
string | ✔️ | N/A |
incidentID |
string | ✔️ | N/A |
patchV1IncidentsIncidentIDNotesNoteID |
components.PatchV1IncidentsIncidentIDNotesNoteID | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UpdateIncidentNoteResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List related changes that have been attached to an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.ListRelatedChangeEvents(ctx, "<id>", nil, nil, nil)
if err != nil {
log.Fatal(err)
}
if res.IncidentsRelatedChangeEventEntityPaginated != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
page |
*int | ➖ | N/A |
perPage |
*int | ➖ | N/A |
type_ |
*operations.QueryParamType | ➖ | The type of the relation to the incident |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ListIncidentRelatedChangesResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Add a related change to an incident. Changes added to an incident can be causes, fixes, or suspects. To remove a change from an incident, the type field should be set to dismissed.
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.CreateRelatedChange(ctx, "<id>", components.PostV1IncidentsIncidentIDRelatedChangeEvents{
ChangeEventID: "<id>",
Type: components.PostV1IncidentsIncidentIDRelatedChangeEventsTypeFixed,
})
if err != nil {
log.Fatal(err)
}
if res.IncidentsRelatedChangeEventEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
postV1IncidentsIncidentIDRelatedChangeEvents |
components.PostV1IncidentsIncidentIDRelatedChangeEvents | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentRelatedChangeResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.ErrorEntity | 400, 409 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.BadRequest | 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Update a change attached to an incident
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.UpdateRelatedChangeEvent(ctx, "<id>", "<id>", components.PatchV1IncidentsIncidentIDRelatedChangeEventsRelatedChangeEventID{})
if err != nil {
log.Fatal(err)
}
if res.IncidentsRelatedChangeEventEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
relatedChangeEventID |
string | ✔️ | N/A |
incidentID |
string | ✔️ | N/A |
patchV1IncidentsIncidentIDRelatedChangeEventsRelatedChangeEventID |
components.PatchV1IncidentsIncidentIDRelatedChangeEventsRelatedChangeEventID | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UpdateIncidentRelatedChangeEventResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.ErrorEntity | 400, 409 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.BadRequest | 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List any parent/child relationships for an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.GetRelationships(ctx, "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentsRelationshipsEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.GetIncidentRelationshipsResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Resolves a currently active incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.Resolve(ctx, "<id>", nil)
if err != nil {
log.Fatal(err)
}
if res.IncidentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
requestBody |
*operations.ResolveIncidentRequestBody | ➖ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ResolveIncidentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Retrieve a list of all of the current role assignments for the incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.ListRoleAssignments(ctx, "<id>", nil)
if err != nil {
log.Fatal(err)
}
if res.IncidentsRoleAssignmentEntityPaginated != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
status |
*operations.Status | ➖ | Filter on status of the role assignment |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ListIncidentRoleAssignmentsResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Assign a role to a user for this incident
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.CreateRoleAssignment(ctx, "<id>", components.PostV1IncidentsIncidentIDRoleAssignments{
UserID: "<id>",
IncidentRoleID: "<id>",
})
if err != nil {
log.Fatal(err)
}
if res.IncidentsRoleAssignmentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
postV1IncidentsIncidentIDRoleAssignments |
components.PostV1IncidentsIncidentIDRoleAssignments | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentRoleAssignmentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Unassign a role from a user
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.DeleteRoleAssignment(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentsRoleAssignmentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
roleAssignmentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.DeleteIncidentRoleAssignmentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List similar incidents
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.ListSimilar(ctx, "<id>", nil, nil)
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
threshold |
*float32 | ➖ | N/A |
limit |
*int | ➖ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.GetSimilarIncidentsResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
List status pages that are attached to an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.ListStatusPages(ctx, "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentsStatusPageEntityPaginated != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.ListIncidentStatusPagesResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Add a status page to an incident.
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.AddStatusPage(ctx, "<id>", components.PostV1IncidentsIncidentIDStatusPages{
IntegrationSlug: "<value>",
IntegrationID: "<id>",
})
if err != nil {
log.Fatal(err)
}
if res.IncidentsStatusPageEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
postV1IncidentsIncidentIDStatusPages |
components.PostV1IncidentsIncidentIDStatusPages | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentStatusPageResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Add all tasks from list to incident
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.CreateTaskList(ctx, "<id>", components.PostV1IncidentsIncidentIDTaskLists{
TaskListID: "<id>",
})
if err != nil {
log.Fatal(err)
}
if res.TaskEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
postV1IncidentsIncidentIDTaskLists |
components.PostV1IncidentsIncidentIDTaskLists | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentTaskListResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Assign a team for this incident
package main
import(
"firehydrant"
"context"
"firehydrant/models/components"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.CreateTeamAssignment(ctx, "<id>", components.PostV1IncidentsIncidentIDTeamAssignments{
TeamID: "<id>",
})
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
postV1IncidentsIncidentIDTeamAssignments |
components.PostV1IncidentsIncidentIDTeamAssignments | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.CreateIncidentTeamAssignmentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Unassign a team from an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.DeleteTeamAssignment(ctx, "<id>", "<id>", nil)
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
teamAssignmentID |
string | ✔️ | N/A |
requestBody |
*operations.DeleteIncidentTeamAssignmentRequestBody | ➖ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.DeleteIncidentTeamAssignmentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Retrieve the transcript for a specific incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.GetTranscript(ctx, "<id>", nil, nil, nil)
if err != nil {
log.Fatal(err)
}
if res.PublicApiv1IncidentsTranscriptEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
after |
*string | ➖ | The ID of the transcript entry to start after. |
before |
*string | ➖ | The ID of the transcript entry to start before. |
sort |
*operations.QueryParamSort | ➖ | The order to sort the transcript entries. |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.GetIncidentTranscriptResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Delete a transcript from an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.DeleteTranscript(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
transcriptID |
string | ✔️ | N/A |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.DeleteIncidentTranscriptResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Unarchives an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.Unarchive(ctx, "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.UnarchiveIncidentResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |
Retrieve a user with current roles for an incident
package main
import(
"firehydrant"
"context"
"log"
)
func main() {
s := firehydrant.New(
firehydrant.WithSecurity("<YOUR_API_KEY_HERE>"),
)
ctx := context.Background()
res, err := s.Incidents.GetUserRole(ctx, "<id>", "<id>")
if err != nil {
log.Fatal(err)
}
if res.IncidentsRoleAssignmentEntity != nil {
// handle response
}
}
Parameter | Type | Required | Description |
---|---|---|---|
ctx |
context.Context | ✔️ | The context to use for the request. |
incidentID |
string | ✔️ | N/A |
userID |
string | ✔️ | N/A |
opts |
[]operations.Option | ➖ | The options for this request. |
*operations.GetIncidentUserRoleResponse, error
Error Type | Status Code | Content Type |
---|---|---|
sdkerrors.BadRequest | 400, 413, 414, 415, 422, 431, 510 | application/json |
sdkerrors.Unauthorized | 401, 403, 407, 511 | application/json |
sdkerrors.NotFound | 404, 501, 505 | application/json |
sdkerrors.Timeout | 408, 504 | application/json |
sdkerrors.RateLimited | 429 | application/json |
sdkerrors.InternalServerError | 500, 502, 503, 506, 507, 508 | application/json |
sdkerrors.SDKError | 4XX, 5XX | */* |