1// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT.
2
3package ozone
4
5// schema: tools.ozone.communication.updateTemplate
6
7import (
8 "context"
9
10 "github.com/bluesky-social/indigo/xrpc"
11)
12
13// CommunicationUpdateTemplate_Input is the input argument to a tools.ozone.communication.updateTemplate call.
14type CommunicationUpdateTemplate_Input struct {
15 // contentMarkdown: Content of the template, markdown supported, can contain variable placeholders.
16 ContentMarkdown *string `json:"contentMarkdown,omitempty" cborgen:"contentMarkdown,omitempty"`
17 Disabled *bool `json:"disabled,omitempty" cborgen:"disabled,omitempty"`
18 // id: ID of the template to be updated.
19 Id string `json:"id" cborgen:"id"`
20 // lang: Message language.
21 Lang *string `json:"lang,omitempty" cborgen:"lang,omitempty"`
22 // name: Name of the template.
23 Name *string `json:"name,omitempty" cborgen:"name,omitempty"`
24 // subject: Subject of the message, used in emails.
25 Subject *string `json:"subject,omitempty" cborgen:"subject,omitempty"`
26 // updatedBy: DID of the user who is updating the template.
27 UpdatedBy *string `json:"updatedBy,omitempty" cborgen:"updatedBy,omitempty"`
28}
29
30// CommunicationUpdateTemplate calls the XRPC method "tools.ozone.communication.updateTemplate".
31func CommunicationUpdateTemplate(ctx context.Context, c *xrpc.Client, input *CommunicationUpdateTemplate_Input) (*CommunicationDefs_TemplateView, error) {
32 var out CommunicationDefs_TemplateView
33 if err := c.Do(ctx, xrpc.Procedure, "application/json", "tools.ozone.communication.updateTemplate", nil, input, &out); err != nil {
34 return nil, err
35 }
36
37 return &out, nil
38}