From d330a9bcb3f401cec85dfd57084793c176a5521c Mon Sep 17 00:00:00 2001 From: Nathaniel Caza Date: Wed, 20 Dec 2023 14:24:43 -0600 Subject: [PATCH] regen --- graphql2/generated.go | 3530 ++++++++++++++++++++++++++++++++-------- graphql2/models_gen.go | 54 + web/src/expflag.d.ts | 2 +- web/src/schema.d.ts | 58 + 4 files changed, 2976 insertions(+), 668 deletions(-) diff --git a/graphql2/generated.go b/graphql2/generated.go index f3b1d9bc7f..b663e26d9b 100644 --- a/graphql2/generated.go +++ b/graphql2/generated.go @@ -213,6 +213,39 @@ type ComplexityRoot struct { ProviderURL func(childComplexity int) int } + Destination struct { + Type func(childComplexity int) int + TypeInfo func(childComplexity int) int + Values func(childComplexity int) int + } + + DestinationFieldConfig struct { + FieldID func(childComplexity int) int + Hint func(childComplexity int) int + HintURL func(childComplexity int) int + InputType func(childComplexity int) int + IsSearchSelectable func(childComplexity int) int + LabelPlural func(childComplexity int) int + LabelSingular func(childComplexity int) int + PlaceholderText func(childComplexity int) int + Prefix func(childComplexity int) int + SupportsValidation func(childComplexity int) int + } + + DestinationTypeInfo struct { + DisabledMessage func(childComplexity int) int + Enabled func(childComplexity int) int + IconAltText func(childComplexity int) int + IconURL func(childComplexity int) int + IsContactMethod func(childComplexity int) int + IsEPTarget func(childComplexity int) int + IsSchedOnCallNotify func(childComplexity int) int + Name func(childComplexity int) int + RequiredFields func(childComplexity int) int + Type func(childComplexity int) int + UserDisclaimer func(childComplexity int) int + } + EscalationPolicy struct { AssignedTo func(childComplexity int) int Description func(childComplexity int) int @@ -237,6 +270,11 @@ type ComplexityRoot struct { Targets func(childComplexity int) int } + FieldValuePair struct { + FieldID func(childComplexity int) int + Value func(childComplexity int) int + } + GQLAPIKey struct { CreatedAt func(childComplexity int) int CreatedBy func(childComplexity int) int @@ -418,6 +456,8 @@ type ComplexityRoot struct { ConfigHints func(childComplexity int) int DebugMessageStatus func(childComplexity int, input DebugMessageStatusInput) int DebugMessages func(childComplexity int, input *DebugMessagesInput) int + DestinationFieldValidate func(childComplexity int, input DestinationFieldValidateInput) int + DestinationTypes func(childComplexity int) int EscalationPolicies func(childComplexity int, input *EscalationPolicySearchOptions) int EscalationPolicy func(childComplexity int, id string) int ExperimentalFlags func(childComplexity int) int @@ -849,6 +889,8 @@ type QueryResolver interface { GenerateSlackAppManifest(ctx context.Context) (string, error) LinkAccountInfo(ctx context.Context, token string) (*LinkAccountInfo, error) SwoStatus(ctx context.Context) (*SWOStatus, error) + DestinationTypes(ctx context.Context) ([]DestinationTypeInfo, error) + DestinationFieldValidate(ctx context.Context, input DestinationFieldValidateInput) (bool, error) GqlAPIKeys(ctx context.Context) ([]GQLAPIKey, error) } type RotationResolver interface { @@ -1435,6 +1477,174 @@ func (e *executableSchema) Complexity(typeName, field string, childComplexity in return e.complexity.DebugSendSMSInfo.ProviderURL(childComplexity), true + case "Destination.type": + if e.complexity.Destination.Type == nil { + break + } + + return e.complexity.Destination.Type(childComplexity), true + + case "Destination.typeInfo": + if e.complexity.Destination.TypeInfo == nil { + break + } + + return e.complexity.Destination.TypeInfo(childComplexity), true + + case "Destination.values": + if e.complexity.Destination.Values == nil { + break + } + + return e.complexity.Destination.Values(childComplexity), true + + case "DestinationFieldConfig.fieldID": + if e.complexity.DestinationFieldConfig.FieldID == nil { + break + } + + return e.complexity.DestinationFieldConfig.FieldID(childComplexity), true + + case "DestinationFieldConfig.hint": + if e.complexity.DestinationFieldConfig.Hint == nil { + break + } + + return e.complexity.DestinationFieldConfig.Hint(childComplexity), true + + case "DestinationFieldConfig.hintURL": + if e.complexity.DestinationFieldConfig.HintURL == nil { + break + } + + return e.complexity.DestinationFieldConfig.HintURL(childComplexity), true + + case "DestinationFieldConfig.inputType": + if e.complexity.DestinationFieldConfig.InputType == nil { + break + } + + return e.complexity.DestinationFieldConfig.InputType(childComplexity), true + + case "DestinationFieldConfig.isSearchSelectable": + if e.complexity.DestinationFieldConfig.IsSearchSelectable == nil { + break + } + + return e.complexity.DestinationFieldConfig.IsSearchSelectable(childComplexity), true + + case "DestinationFieldConfig.labelPlural": + if e.complexity.DestinationFieldConfig.LabelPlural == nil { + break + } + + return e.complexity.DestinationFieldConfig.LabelPlural(childComplexity), true + + case "DestinationFieldConfig.labelSingular": + if e.complexity.DestinationFieldConfig.LabelSingular == nil { + break + } + + return e.complexity.DestinationFieldConfig.LabelSingular(childComplexity), true + + case "DestinationFieldConfig.placeholderText": + if e.complexity.DestinationFieldConfig.PlaceholderText == nil { + break + } + + return e.complexity.DestinationFieldConfig.PlaceholderText(childComplexity), true + + case "DestinationFieldConfig.prefix": + if e.complexity.DestinationFieldConfig.Prefix == nil { + break + } + + return e.complexity.DestinationFieldConfig.Prefix(childComplexity), true + + case "DestinationFieldConfig.supportsValidation": + if e.complexity.DestinationFieldConfig.SupportsValidation == nil { + break + } + + return e.complexity.DestinationFieldConfig.SupportsValidation(childComplexity), true + + case "DestinationTypeInfo.disabledMessage": + if e.complexity.DestinationTypeInfo.DisabledMessage == nil { + break + } + + return e.complexity.DestinationTypeInfo.DisabledMessage(childComplexity), true + + case "DestinationTypeInfo.enabled": + if e.complexity.DestinationTypeInfo.Enabled == nil { + break + } + + return e.complexity.DestinationTypeInfo.Enabled(childComplexity), true + + case "DestinationTypeInfo.iconAltText": + if e.complexity.DestinationTypeInfo.IconAltText == nil { + break + } + + return e.complexity.DestinationTypeInfo.IconAltText(childComplexity), true + + case "DestinationTypeInfo.iconURL": + if e.complexity.DestinationTypeInfo.IconURL == nil { + break + } + + return e.complexity.DestinationTypeInfo.IconURL(childComplexity), true + + case "DestinationTypeInfo.isContactMethod": + if e.complexity.DestinationTypeInfo.IsContactMethod == nil { + break + } + + return e.complexity.DestinationTypeInfo.IsContactMethod(childComplexity), true + + case "DestinationTypeInfo.isEPTarget": + if e.complexity.DestinationTypeInfo.IsEPTarget == nil { + break + } + + return e.complexity.DestinationTypeInfo.IsEPTarget(childComplexity), true + + case "DestinationTypeInfo.isSchedOnCallNotify": + if e.complexity.DestinationTypeInfo.IsSchedOnCallNotify == nil { + break + } + + return e.complexity.DestinationTypeInfo.IsSchedOnCallNotify(childComplexity), true + + case "DestinationTypeInfo.name": + if e.complexity.DestinationTypeInfo.Name == nil { + break + } + + return e.complexity.DestinationTypeInfo.Name(childComplexity), true + + case "DestinationTypeInfo.requiredFields": + if e.complexity.DestinationTypeInfo.RequiredFields == nil { + break + } + + return e.complexity.DestinationTypeInfo.RequiredFields(childComplexity), true + + case "DestinationTypeInfo.type": + if e.complexity.DestinationTypeInfo.Type == nil { + break + } + + return e.complexity.DestinationTypeInfo.Type(childComplexity), true + + case "DestinationTypeInfo.userDisclaimer": + if e.complexity.DestinationTypeInfo.UserDisclaimer == nil { + break + } + + return e.complexity.DestinationTypeInfo.UserDisclaimer(childComplexity), true + case "EscalationPolicy.assignedTo": if e.complexity.EscalationPolicy.AssignedTo == nil { break @@ -1540,6 +1750,20 @@ func (e *executableSchema) Complexity(typeName, field string, childComplexity in return e.complexity.EscalationPolicyStep.Targets(childComplexity), true + case "FieldValuePair.fieldID": + if e.complexity.FieldValuePair.FieldID == nil { + break + } + + return e.complexity.FieldValuePair.FieldID(childComplexity), true + + case "FieldValuePair.value": + if e.complexity.FieldValuePair.Value == nil { + break + } + + return e.complexity.FieldValuePair.Value(childComplexity), true + case "GQLAPIKey.createdAt": if e.complexity.GQLAPIKey.CreatedAt == nil { break @@ -2717,6 +2941,25 @@ func (e *executableSchema) Complexity(typeName, field string, childComplexity in return e.complexity.Query.DebugMessages(childComplexity, args["input"].(*DebugMessagesInput)), true + case "Query.destinationFieldValidate": + if e.complexity.Query.DestinationFieldValidate == nil { + break + } + + args, err := ec.field_Query_destinationFieldValidate_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.DestinationFieldValidate(childComplexity, args["input"].(DestinationFieldValidateInput)), true + + case "Query.destinationTypes": + if e.complexity.Query.DestinationTypes == nil { + break + } + + return e.complexity.Query.DestinationTypes(childComplexity), true + case "Query.escalationPolicies": if e.complexity.Query.EscalationPolicies == nil { break @@ -4202,7 +4445,10 @@ func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler { ec.unmarshalInputDebugMessageStatusInput, ec.unmarshalInputDebugMessagesInput, ec.unmarshalInputDebugSendSMSInput, + ec.unmarshalInputDestinationFieldValidateInput, + ec.unmarshalInputDestinationInput, ec.unmarshalInputEscalationPolicySearchOptions, + ec.unmarshalInputFieldValueInput, ec.unmarshalInputIntegrationKeySearchOptions, ec.unmarshalInputLabelKeySearchOptions, ec.unmarshalInputLabelSearchOptions, @@ -4340,7 +4586,7 @@ func (ec *executionContext) introspectType(name string) (*introspection.Type, er return introspection.WrapTypeFromDef(ec.Schema(), ec.Schema().Types[name]), nil } -//go:embed "schema.graphql" "graph/_Mutation.graphqls" "graph/_Query.graphqls" "graph/_directives.graphqls" "graph/gqlapikeys.graphqls" +//go:embed "schema.graphql" "graph/_Mutation.graphqls" "graph/_Query.graphqls" "graph/_directives.graphqls" "graph/destinations.graphqls" "graph/gqlapikeys.graphqls" var sourcesFS embed.FS func sourceData(filename string) string { @@ -4356,6 +4602,7 @@ var sources = []*ast.Source{ {Name: "graph/_Mutation.graphqls", Input: sourceData("graph/_Mutation.graphqls"), BuiltIn: false}, {Name: "graph/_Query.graphqls", Input: sourceData("graph/_Query.graphqls"), BuiltIn: false}, {Name: "graph/_directives.graphqls", Input: sourceData("graph/_directives.graphqls"), BuiltIn: false}, + {Name: "graph/destinations.graphqls", Input: sourceData("graph/destinations.graphqls"), BuiltIn: false}, {Name: "graph/gqlapikeys.graphqls", Input: sourceData("graph/gqlapikeys.graphqls"), BuiltIn: false}, } var parsedSchema = gqlparser.MustLoadSchema(sources...) @@ -5297,6 +5544,21 @@ func (ec *executionContext) field_Query_debugMessages_args(ctx context.Context, return args, nil } +func (ec *executionContext) field_Query_destinationFieldValidate_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 DestinationFieldValidateInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNDestinationFieldValidateInput2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationFieldValidateInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + func (ec *executionContext) field_Query_escalationPolicies_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { var err error args := map[string]interface{}{} @@ -7172,9 +7434,1378 @@ func (ec *executionContext) _AlertPendingNotification_destination(ctx context.Co return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_AlertPendingNotification_destination(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_AlertPendingNotification_destination(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AlertPendingNotification", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _AlertState_lastEscalation(ctx context.Context, field graphql.CollectedField, obj *alert.State) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AlertState_lastEscalation(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.LastEscalation, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(time.Time) + fc.Result = res + return ec.marshalNISOTimestamp2timeᚐTime(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_AlertState_lastEscalation(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AlertState", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ISOTimestamp does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _AlertState_stepNumber(ctx context.Context, field graphql.CollectedField, obj *alert.State) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AlertState_stepNumber(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.StepNumber, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_AlertState_stepNumber(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AlertState", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _AlertState_repeatCount(ctx context.Context, field graphql.CollectedField, obj *alert.State) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AlertState_repeatCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.RepeatCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_AlertState_repeatCount(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AlertState", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _AuthSubject_providerID(ctx context.Context, field graphql.CollectedField, obj *user.AuthSubject) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AuthSubject_providerID(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ProviderID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_AuthSubject_providerID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AuthSubject", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _AuthSubject_subjectID(ctx context.Context, field graphql.CollectedField, obj *user.AuthSubject) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AuthSubject_subjectID(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.SubjectID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_AuthSubject_subjectID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AuthSubject", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _AuthSubject_userID(ctx context.Context, field graphql.CollectedField, obj *user.AuthSubject) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AuthSubject_userID(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UserID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_AuthSubject_userID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AuthSubject", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _AuthSubjectConnection_nodes(ctx context.Context, field graphql.CollectedField, obj *AuthSubjectConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AuthSubjectConnection_nodes(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Nodes, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]user.AuthSubject) + fc.Result = res + return ec.marshalNAuthSubject2ᚕgithubᚗcomᚋtargetᚋgoalertᚋuserᚐAuthSubjectᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_AuthSubjectConnection_nodes(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AuthSubjectConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "providerID": + return ec.fieldContext_AuthSubject_providerID(ctx, field) + case "subjectID": + return ec.fieldContext_AuthSubject_subjectID(ctx, field) + case "userID": + return ec.fieldContext_AuthSubject_userID(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type AuthSubject", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _AuthSubjectConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *AuthSubjectConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AuthSubjectConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*PageInfo) + fc.Result = res + return ec.marshalNPageInfo2ᚖgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_AuthSubjectConnection_pageInfo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AuthSubjectConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "endCursor": + return ec.fieldContext_PageInfo_endCursor(ctx, field) + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ConfigHint_id(ctx context.Context, field graphql.CollectedField, obj *ConfigHint) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ConfigHint_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ConfigHint_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ConfigHint", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ConfigHint_value(ctx context.Context, field graphql.CollectedField, obj *ConfigHint) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ConfigHint_value(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Value, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ConfigHint_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ConfigHint", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ConfigValue_id(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ConfigValue_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ConfigValue_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ConfigValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ConfigValue_description(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ConfigValue_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Description, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ConfigValue_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ConfigValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ConfigValue_value(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ConfigValue_value(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Value, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ConfigValue_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ConfigValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ConfigValue_type(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ConfigValue_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Type, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(ConfigType) + fc.Result = res + return ec.marshalNConfigType2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐConfigType(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ConfigValue_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ConfigValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ConfigType does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ConfigValue_password(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ConfigValue_password(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Password, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(bool) + fc.Result = res + return ec.marshalNBoolean2bool(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ConfigValue_password(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ConfigValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ConfigValue_deprecated(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ConfigValue_deprecated(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Deprecated, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ConfigValue_deprecated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ConfigValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CreatedGQLAPIKey_id(ctx context.Context, field graphql.CollectedField, obj *CreatedGQLAPIKey) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CreatedGQLAPIKey_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CreatedGQLAPIKey_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CreatedGQLAPIKey", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CreatedGQLAPIKey_token(ctx context.Context, field graphql.CollectedField, obj *CreatedGQLAPIKey) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CreatedGQLAPIKey_token(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Token, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CreatedGQLAPIKey_token(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CreatedGQLAPIKey", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugCarrierInfo_name(ctx context.Context, field graphql.CollectedField, obj *twilio.CarrierInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugCarrierInfo_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugCarrierInfo_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugCarrierInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugCarrierInfo_type(ctx context.Context, field graphql.CollectedField, obj *twilio.CarrierInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugCarrierInfo_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Type, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugCarrierInfo_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugCarrierInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugCarrierInfo_mobileNetworkCode(ctx context.Context, field graphql.CollectedField, obj *twilio.CarrierInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugCarrierInfo_mobileNetworkCode(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.MobileNetworkCode, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugCarrierInfo_mobileNetworkCode(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugCarrierInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugCarrierInfo_mobileCountryCode(ctx context.Context, field graphql.CollectedField, obj *twilio.CarrierInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugCarrierInfo_mobileCountryCode(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.MobileCountryCode, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugCarrierInfo_mobileCountryCode(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugCarrierInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugMessage_id(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugMessage_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugMessage", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugMessage_createdAt(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_createdAt(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.CreatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(time.Time) + fc.Result = res + return ec.marshalNISOTimestamp2timeᚐTime(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugMessage_createdAt(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugMessage", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ISOTimestamp does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugMessage_updatedAt(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_updatedAt(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UpdatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(time.Time) + fc.Result = res + return ec.marshalNISOTimestamp2timeᚐTime(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugMessage_updatedAt(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugMessage", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ISOTimestamp does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugMessage_type(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Type, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugMessage_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugMessage", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugMessage_status(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_status(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Status, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugMessage_status(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugMessage", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugMessage_userID(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_userID(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UserID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOID2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugMessage_userID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugMessage", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugMessage_userName(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_userName(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UserName, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugMessage_userName(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugMessage", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugMessage_source(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_source(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Source, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugMessage_source(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DebugMessage", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _DebugMessage_destination(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_destination(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Destination, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_DebugMessage_destination(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "AlertPendingNotification", + Object: "DebugMessage", Field: field, IsMethod: false, IsResolver: false, @@ -7185,8 +8816,8 @@ func (ec *executionContext) fieldContext_AlertPendingNotification_destination(ct return fc, nil } -func (ec *executionContext) _AlertState_lastEscalation(ctx context.Context, field graphql.CollectedField, obj *alert.State) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_AlertState_lastEscalation(ctx, field) +func (ec *executionContext) _DebugMessage_serviceID(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_serviceID(ctx, field) if err != nil { return graphql.Null } @@ -7199,38 +8830,35 @@ func (ec *executionContext) _AlertState_lastEscalation(ctx context.Context, fiel }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.LastEscalation, nil + return obj.ServiceID, nil }) if err != nil { ec.Error(ctx, err) return graphql.Null } if resTmp == nil { - if !graphql.HasFieldError(ctx, fc) { - ec.Errorf(ctx, "must not be null") - } return graphql.Null } - res := resTmp.(time.Time) + res := resTmp.(*string) fc.Result = res - return ec.marshalNISOTimestamp2timeᚐTime(ctx, field.Selections, res) + return ec.marshalOID2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_AlertState_lastEscalation(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugMessage_serviceID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "AlertState", + Object: "DebugMessage", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ISOTimestamp does not have child fields") + return nil, errors.New("field of type ID does not have child fields") }, } return fc, nil } -func (ec *executionContext) _AlertState_stepNumber(ctx context.Context, field graphql.CollectedField, obj *alert.State) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_AlertState_stepNumber(ctx, field) +func (ec *executionContext) _DebugMessage_serviceName(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_serviceName(ctx, field) if err != nil { return graphql.Null } @@ -7243,38 +8871,35 @@ func (ec *executionContext) _AlertState_stepNumber(ctx context.Context, field gr }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.StepNumber, nil + return obj.ServiceName, nil }) if err != nil { ec.Error(ctx, err) return graphql.Null } if resTmp == nil { - if !graphql.HasFieldError(ctx, fc) { - ec.Errorf(ctx, "must not be null") - } return graphql.Null } - res := resTmp.(int) + res := resTmp.(*string) fc.Result = res - return ec.marshalNInt2int(ctx, field.Selections, res) + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_AlertState_stepNumber(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugMessage_serviceName(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "AlertState", + Object: "DebugMessage", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type Int does not have child fields") + return nil, errors.New("field of type String does not have child fields") }, } return fc, nil } -func (ec *executionContext) _AlertState_repeatCount(ctx context.Context, field graphql.CollectedField, obj *alert.State) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_AlertState_repeatCount(ctx, field) +func (ec *executionContext) _DebugMessage_alertID(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_alertID(ctx, field) if err != nil { return graphql.Null } @@ -7287,26 +8912,23 @@ func (ec *executionContext) _AlertState_repeatCount(ctx context.Context, field g }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.RepeatCount, nil + return obj.AlertID, nil }) if err != nil { ec.Error(ctx, err) return graphql.Null } if resTmp == nil { - if !graphql.HasFieldError(ctx, fc) { - ec.Errorf(ctx, "must not be null") - } return graphql.Null } - res := resTmp.(int) + res := resTmp.(*int) fc.Result = res - return ec.marshalNInt2int(ctx, field.Selections, res) + return ec.marshalOInt2ᚖint(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_AlertState_repeatCount(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugMessage_alertID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "AlertState", + Object: "DebugMessage", Field: field, IsMethod: false, IsResolver: false, @@ -7317,8 +8939,8 @@ func (ec *executionContext) fieldContext_AlertState_repeatCount(ctx context.Cont return fc, nil } -func (ec *executionContext) _AuthSubject_providerID(ctx context.Context, field graphql.CollectedField, obj *user.AuthSubject) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_AuthSubject_providerID(ctx, field) +func (ec *executionContext) _DebugMessage_providerID(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_providerID(ctx, field) if err != nil { return graphql.Null } @@ -7338,63 +8960,16 @@ func (ec *executionContext) _AuthSubject_providerID(ctx context.Context, field g return graphql.Null } if resTmp == nil { - if !graphql.HasFieldError(ctx, fc) { - ec.Errorf(ctx, "must not be null") - } - return graphql.Null - } - res := resTmp.(string) - fc.Result = res - return ec.marshalNID2string(ctx, field.Selections, res) -} - -func (ec *executionContext) fieldContext_AuthSubject_providerID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { - fc = &graphql.FieldContext{ - Object: "AuthSubject", - Field: field, - IsMethod: false, - IsResolver: false, - Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ID does not have child fields") - }, - } - return fc, nil -} - -func (ec *executionContext) _AuthSubject_subjectID(ctx context.Context, field graphql.CollectedField, obj *user.AuthSubject) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_AuthSubject_subjectID(ctx, field) - if err != nil { return graphql.Null } - ctx = graphql.WithFieldContext(ctx, fc) - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { - ctx = rctx // use context from middleware stack in children - return obj.SubjectID, nil - }) - if err != nil { - ec.Error(ctx, err) - return graphql.Null - } - if resTmp == nil { - if !graphql.HasFieldError(ctx, fc) { - ec.Errorf(ctx, "must not be null") - } - return graphql.Null - } - res := resTmp.(string) + res := resTmp.(*string) fc.Result = res - return ec.marshalNID2string(ctx, field.Selections, res) + return ec.marshalOID2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_AuthSubject_subjectID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugMessage_providerID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "AuthSubject", + Object: "DebugMessage", Field: field, IsMethod: false, IsResolver: false, @@ -7405,8 +8980,8 @@ func (ec *executionContext) fieldContext_AuthSubject_subjectID(ctx context.Conte return fc, nil } -func (ec *executionContext) _AuthSubject_userID(ctx context.Context, field graphql.CollectedField, obj *user.AuthSubject) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_AuthSubject_userID(ctx, field) +func (ec *executionContext) _DebugMessage_sentAt(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_sentAt(ctx, field) if err != nil { return graphql.Null } @@ -7419,38 +8994,35 @@ func (ec *executionContext) _AuthSubject_userID(ctx context.Context, field graph }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.UserID, nil + return obj.SentAt, nil }) if err != nil { ec.Error(ctx, err) return graphql.Null } if resTmp == nil { - if !graphql.HasFieldError(ctx, fc) { - ec.Errorf(ctx, "must not be null") - } return graphql.Null } - res := resTmp.(string) + res := resTmp.(*time.Time) fc.Result = res - return ec.marshalNID2string(ctx, field.Selections, res) + return ec.marshalOISOTimestamp2ᚖtimeᚐTime(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_AuthSubject_userID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugMessage_sentAt(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "AuthSubject", + Object: "DebugMessage", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ID does not have child fields") + return nil, errors.New("field of type ISOTimestamp does not have child fields") }, } return fc, nil } -func (ec *executionContext) _AuthSubjectConnection_nodes(ctx context.Context, field graphql.CollectedField, obj *AuthSubjectConnection) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_AuthSubjectConnection_nodes(ctx, field) +func (ec *executionContext) _DebugMessage_retryCount(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessage_retryCount(ctx, field) if err != nil { return graphql.Null } @@ -7463,7 +9035,7 @@ func (ec *executionContext) _AuthSubjectConnection_nodes(ctx context.Context, fi }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Nodes, nil + return obj.RetryCount, nil }) if err != nil { ec.Error(ctx, err) @@ -7475,34 +9047,26 @@ func (ec *executionContext) _AuthSubjectConnection_nodes(ctx context.Context, fi } return graphql.Null } - res := resTmp.([]user.AuthSubject) + res := resTmp.(int) fc.Result = res - return ec.marshalNAuthSubject2ᚕgithubᚗcomᚋtargetᚋgoalertᚋuserᚐAuthSubjectᚄ(ctx, field.Selections, res) + return ec.marshalNInt2int(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_AuthSubjectConnection_nodes(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugMessage_retryCount(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "AuthSubjectConnection", + Object: "DebugMessage", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - switch field.Name { - case "providerID": - return ec.fieldContext_AuthSubject_providerID(ctx, field) - case "subjectID": - return ec.fieldContext_AuthSubject_subjectID(ctx, field) - case "userID": - return ec.fieldContext_AuthSubject_userID(ctx, field) - } - return nil, fmt.Errorf("no field named %q was found under type AuthSubject", field.Name) + return nil, errors.New("field of type Int does not have child fields") }, } return fc, nil } -func (ec *executionContext) _AuthSubjectConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *AuthSubjectConnection) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_AuthSubjectConnection_pageInfo(ctx, field) +func (ec *executionContext) _DebugMessageStatusInfo_state(ctx context.Context, field graphql.CollectedField, obj *DebugMessageStatusInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugMessageStatusInfo_state(ctx, field) if err != nil { return graphql.Null } @@ -7515,7 +9079,7 @@ func (ec *executionContext) _AuthSubjectConnection_pageInfo(ctx context.Context, }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.PageInfo, nil + return obj.State, nil }) if err != nil { ec.Error(ctx, err) @@ -7527,32 +9091,34 @@ func (ec *executionContext) _AuthSubjectConnection_pageInfo(ctx context.Context, } return graphql.Null } - res := resTmp.(*PageInfo) + res := resTmp.(*NotificationState) fc.Result = res - return ec.marshalNPageInfo2ᚖgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐPageInfo(ctx, field.Selections, res) + return ec.marshalNNotificationState2ᚖgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐNotificationState(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_AuthSubjectConnection_pageInfo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugMessageStatusInfo_state(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "AuthSubjectConnection", + Object: "DebugMessageStatusInfo", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { switch field.Name { - case "endCursor": - return ec.fieldContext_PageInfo_endCursor(ctx, field) - case "hasNextPage": - return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "details": + return ec.fieldContext_NotificationState_details(ctx, field) + case "status": + return ec.fieldContext_NotificationState_status(ctx, field) + case "formattedSrcValue": + return ec.fieldContext_NotificationState_formattedSrcValue(ctx, field) } - return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + return nil, fmt.Errorf("no field named %q was found under type NotificationState", field.Name) }, } return fc, nil } -func (ec *executionContext) _ConfigHint_id(ctx context.Context, field graphql.CollectedField, obj *ConfigHint) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_ConfigHint_id(ctx, field) +func (ec *executionContext) _DebugSendSMSInfo_id(ctx context.Context, field graphql.CollectedField, obj *DebugSendSMSInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugSendSMSInfo_id(ctx, field) if err != nil { return graphql.Null } @@ -7579,24 +9145,24 @@ func (ec *executionContext) _ConfigHint_id(ctx context.Context, field graphql.Co } res := resTmp.(string) fc.Result = res - return ec.marshalNString2string(ctx, field.Selections, res) + return ec.marshalNID2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_ConfigHint_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugSendSMSInfo_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "ConfigHint", + Object: "DebugSendSMSInfo", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type String does not have child fields") + return nil, errors.New("field of type ID does not have child fields") }, } return fc, nil } -func (ec *executionContext) _ConfigHint_value(ctx context.Context, field graphql.CollectedField, obj *ConfigHint) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_ConfigHint_value(ctx, field) +func (ec *executionContext) _DebugSendSMSInfo_providerURL(ctx context.Context, field graphql.CollectedField, obj *DebugSendSMSInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugSendSMSInfo_providerURL(ctx, field) if err != nil { return graphql.Null } @@ -7609,7 +9175,7 @@ func (ec *executionContext) _ConfigHint_value(ctx context.Context, field graphql }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Value, nil + return obj.ProviderURL, nil }) if err != nil { ec.Error(ctx, err) @@ -7626,9 +9192,9 @@ func (ec *executionContext) _ConfigHint_value(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_ConfigHint_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugSendSMSInfo_providerURL(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "ConfigHint", + Object: "DebugSendSMSInfo", Field: field, IsMethod: false, IsResolver: false, @@ -7639,8 +9205,8 @@ func (ec *executionContext) fieldContext_ConfigHint_value(ctx context.Context, f return fc, nil } -func (ec *executionContext) _ConfigValue_id(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_ConfigValue_id(ctx, field) +func (ec *executionContext) _DebugSendSMSInfo_fromNumber(ctx context.Context, field graphql.CollectedField, obj *DebugSendSMSInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DebugSendSMSInfo_fromNumber(ctx, field) if err != nil { return graphql.Null } @@ -7653,7 +9219,7 @@ func (ec *executionContext) _ConfigValue_id(ctx context.Context, field graphql.C }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.ID, nil + return obj.FromNumber, nil }) if err != nil { ec.Error(ctx, err) @@ -7670,9 +9236,9 @@ func (ec *executionContext) _ConfigValue_id(ctx context.Context, field graphql.C return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_ConfigValue_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DebugSendSMSInfo_fromNumber(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "ConfigValue", + Object: "DebugSendSMSInfo", Field: field, IsMethod: false, IsResolver: false, @@ -7683,8 +9249,8 @@ func (ec *executionContext) fieldContext_ConfigValue_id(ctx context.Context, fie return fc, nil } -func (ec *executionContext) _ConfigValue_description(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_ConfigValue_description(ctx, field) +func (ec *executionContext) _Destination_type(ctx context.Context, field graphql.CollectedField, obj *Destination) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Destination_type(ctx, field) if err != nil { return graphql.Null } @@ -7697,7 +9263,7 @@ func (ec *executionContext) _ConfigValue_description(ctx context.Context, field }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Description, nil + return obj.Type, nil }) if err != nil { ec.Error(ctx, err) @@ -7711,24 +9277,24 @@ func (ec *executionContext) _ConfigValue_description(ctx context.Context, field } res := resTmp.(string) fc.Result = res - return ec.marshalNString2string(ctx, field.Selections, res) + return ec.marshalNDestinationType2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_ConfigValue_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_Destination_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "ConfigValue", + Object: "Destination", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type String does not have child fields") + return nil, errors.New("field of type DestinationType does not have child fields") }, } return fc, nil } -func (ec *executionContext) _ConfigValue_value(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_ConfigValue_value(ctx, field) +func (ec *executionContext) _Destination_values(ctx context.Context, field graphql.CollectedField, obj *Destination) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Destination_values(ctx, field) if err != nil { return graphql.Null } @@ -7741,7 +9307,7 @@ func (ec *executionContext) _ConfigValue_value(ctx context.Context, field graphq }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Value, nil + return obj.Values, nil }) if err != nil { ec.Error(ctx, err) @@ -7753,26 +9319,32 @@ func (ec *executionContext) _ConfigValue_value(ctx context.Context, field graphq } return graphql.Null } - res := resTmp.(string) + res := resTmp.([]FieldValuePair) fc.Result = res - return ec.marshalNString2string(ctx, field.Selections, res) + return ec.marshalNFieldValuePair2ᚕgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐFieldValuePairᚄ(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_ConfigValue_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_Destination_values(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "ConfigValue", + Object: "Destination", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type String does not have child fields") + switch field.Name { + case "fieldID": + return ec.fieldContext_FieldValuePair_fieldID(ctx, field) + case "value": + return ec.fieldContext_FieldValuePair_value(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type FieldValuePair", field.Name) }, } return fc, nil } -func (ec *executionContext) _ConfigValue_type(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_ConfigValue_type(ctx, field) +func (ec *executionContext) _Destination_typeInfo(ctx context.Context, field graphql.CollectedField, obj *Destination) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Destination_typeInfo(ctx, field) if err != nil { return graphql.Null } @@ -7785,7 +9357,7 @@ func (ec *executionContext) _ConfigValue_type(ctx context.Context, field graphql }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Type, nil + return obj.TypeInfo, nil }) if err != nil { ec.Error(ctx, err) @@ -7797,26 +9369,50 @@ func (ec *executionContext) _ConfigValue_type(ctx context.Context, field graphql } return graphql.Null } - res := resTmp.(ConfigType) + res := resTmp.(*DestinationTypeInfo) fc.Result = res - return ec.marshalNConfigType2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐConfigType(ctx, field.Selections, res) + return ec.marshalNDestinationTypeInfo2ᚖgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationTypeInfo(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_ConfigValue_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_Destination_typeInfo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "ConfigValue", + Object: "Destination", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ConfigType does not have child fields") + switch field.Name { + case "type": + return ec.fieldContext_DestinationTypeInfo_type(ctx, field) + case "name": + return ec.fieldContext_DestinationTypeInfo_name(ctx, field) + case "iconURL": + return ec.fieldContext_DestinationTypeInfo_iconURL(ctx, field) + case "iconAltText": + return ec.fieldContext_DestinationTypeInfo_iconAltText(ctx, field) + case "disabledMessage": + return ec.fieldContext_DestinationTypeInfo_disabledMessage(ctx, field) + case "enabled": + return ec.fieldContext_DestinationTypeInfo_enabled(ctx, field) + case "requiredFields": + return ec.fieldContext_DestinationTypeInfo_requiredFields(ctx, field) + case "userDisclaimer": + return ec.fieldContext_DestinationTypeInfo_userDisclaimer(ctx, field) + case "isContactMethod": + return ec.fieldContext_DestinationTypeInfo_isContactMethod(ctx, field) + case "isEPTarget": + return ec.fieldContext_DestinationTypeInfo_isEPTarget(ctx, field) + case "isSchedOnCallNotify": + return ec.fieldContext_DestinationTypeInfo_isSchedOnCallNotify(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type DestinationTypeInfo", field.Name) }, } return fc, nil } -func (ec *executionContext) _ConfigValue_password(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_ConfigValue_password(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_fieldID(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_fieldID(ctx, field) if err != nil { return graphql.Null } @@ -7829,7 +9425,7 @@ func (ec *executionContext) _ConfigValue_password(ctx context.Context, field gra }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Password, nil + return obj.FieldID, nil }) if err != nil { ec.Error(ctx, err) @@ -7841,26 +9437,26 @@ func (ec *executionContext) _ConfigValue_password(ctx context.Context, field gra } return graphql.Null } - res := resTmp.(bool) + res := resTmp.(string) fc.Result = res - return ec.marshalNBoolean2bool(ctx, field.Selections, res) + return ec.marshalNID2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_ConfigValue_password(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_fieldID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "ConfigValue", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type Boolean does not have child fields") + return nil, errors.New("field of type ID does not have child fields") }, } return fc, nil } -func (ec *executionContext) _ConfigValue_deprecated(ctx context.Context, field graphql.CollectedField, obj *ConfigValue) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_ConfigValue_deprecated(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_labelSingular(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_labelSingular(ctx, field) if err != nil { return graphql.Null } @@ -7873,7 +9469,7 @@ func (ec *executionContext) _ConfigValue_deprecated(ctx context.Context, field g }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Deprecated, nil + return obj.LabelSingular, nil }) if err != nil { ec.Error(ctx, err) @@ -7890,9 +9486,9 @@ func (ec *executionContext) _ConfigValue_deprecated(ctx context.Context, field g return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_ConfigValue_deprecated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_labelSingular(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "ConfigValue", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, @@ -7903,52 +9499,8 @@ func (ec *executionContext) fieldContext_ConfigValue_deprecated(ctx context.Cont return fc, nil } -func (ec *executionContext) _CreatedGQLAPIKey_id(ctx context.Context, field graphql.CollectedField, obj *CreatedGQLAPIKey) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_CreatedGQLAPIKey_id(ctx, field) - if err != nil { - return graphql.Null - } - ctx = graphql.WithFieldContext(ctx, fc) - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { - ctx = rctx // use context from middleware stack in children - return obj.ID, nil - }) - if err != nil { - ec.Error(ctx, err) - return graphql.Null - } - if resTmp == nil { - if !graphql.HasFieldError(ctx, fc) { - ec.Errorf(ctx, "must not be null") - } - return graphql.Null - } - res := resTmp.(string) - fc.Result = res - return ec.marshalNID2string(ctx, field.Selections, res) -} - -func (ec *executionContext) fieldContext_CreatedGQLAPIKey_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { - fc = &graphql.FieldContext{ - Object: "CreatedGQLAPIKey", - Field: field, - IsMethod: false, - IsResolver: false, - Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ID does not have child fields") - }, - } - return fc, nil -} - -func (ec *executionContext) _CreatedGQLAPIKey_token(ctx context.Context, field graphql.CollectedField, obj *CreatedGQLAPIKey) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_CreatedGQLAPIKey_token(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_labelPlural(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_labelPlural(ctx, field) if err != nil { return graphql.Null } @@ -7961,7 +9513,7 @@ func (ec *executionContext) _CreatedGQLAPIKey_token(ctx context.Context, field g }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Token, nil + return obj.LabelPlural, nil }) if err != nil { ec.Error(ctx, err) @@ -7978,9 +9530,9 @@ func (ec *executionContext) _CreatedGQLAPIKey_token(ctx context.Context, field g return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_CreatedGQLAPIKey_token(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_labelPlural(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "CreatedGQLAPIKey", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, @@ -7991,8 +9543,8 @@ func (ec *executionContext) fieldContext_CreatedGQLAPIKey_token(ctx context.Cont return fc, nil } -func (ec *executionContext) _DebugCarrierInfo_name(ctx context.Context, field graphql.CollectedField, obj *twilio.CarrierInfo) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugCarrierInfo_name(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_hint(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_hint(ctx, field) if err != nil { return graphql.Null } @@ -8005,7 +9557,7 @@ func (ec *executionContext) _DebugCarrierInfo_name(ctx context.Context, field gr }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Name, nil + return obj.Hint, nil }) if err != nil { ec.Error(ctx, err) @@ -8022,9 +9574,9 @@ func (ec *executionContext) _DebugCarrierInfo_name(ctx context.Context, field gr return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugCarrierInfo_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_hint(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugCarrierInfo", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, @@ -8035,8 +9587,8 @@ func (ec *executionContext) fieldContext_DebugCarrierInfo_name(ctx context.Conte return fc, nil } -func (ec *executionContext) _DebugCarrierInfo_type(ctx context.Context, field graphql.CollectedField, obj *twilio.CarrierInfo) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugCarrierInfo_type(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_hintURL(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_hintURL(ctx, field) if err != nil { return graphql.Null } @@ -8049,7 +9601,7 @@ func (ec *executionContext) _DebugCarrierInfo_type(ctx context.Context, field gr }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Type, nil + return obj.HintURL, nil }) if err != nil { ec.Error(ctx, err) @@ -8066,9 +9618,9 @@ func (ec *executionContext) _DebugCarrierInfo_type(ctx context.Context, field gr return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugCarrierInfo_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_hintURL(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugCarrierInfo", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, @@ -8079,8 +9631,8 @@ func (ec *executionContext) fieldContext_DebugCarrierInfo_type(ctx context.Conte return fc, nil } -func (ec *executionContext) _DebugCarrierInfo_mobileNetworkCode(ctx context.Context, field graphql.CollectedField, obj *twilio.CarrierInfo) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugCarrierInfo_mobileNetworkCode(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_placeholderText(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_placeholderText(ctx, field) if err != nil { return graphql.Null } @@ -8093,7 +9645,7 @@ func (ec *executionContext) _DebugCarrierInfo_mobileNetworkCode(ctx context.Cont }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.MobileNetworkCode, nil + return obj.PlaceholderText, nil }) if err != nil { ec.Error(ctx, err) @@ -8110,9 +9662,9 @@ func (ec *executionContext) _DebugCarrierInfo_mobileNetworkCode(ctx context.Cont return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugCarrierInfo_mobileNetworkCode(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_placeholderText(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugCarrierInfo", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, @@ -8123,8 +9675,8 @@ func (ec *executionContext) fieldContext_DebugCarrierInfo_mobileNetworkCode(ctx return fc, nil } -func (ec *executionContext) _DebugCarrierInfo_mobileCountryCode(ctx context.Context, field graphql.CollectedField, obj *twilio.CarrierInfo) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugCarrierInfo_mobileCountryCode(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_prefix(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_prefix(ctx, field) if err != nil { return graphql.Null } @@ -8137,7 +9689,7 @@ func (ec *executionContext) _DebugCarrierInfo_mobileCountryCode(ctx context.Cont }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.MobileCountryCode, nil + return obj.Prefix, nil }) if err != nil { ec.Error(ctx, err) @@ -8154,9 +9706,9 @@ func (ec *executionContext) _DebugCarrierInfo_mobileCountryCode(ctx context.Cont return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugCarrierInfo_mobileCountryCode(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_prefix(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugCarrierInfo", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, @@ -8167,8 +9719,8 @@ func (ec *executionContext) fieldContext_DebugCarrierInfo_mobileCountryCode(ctx return fc, nil } -func (ec *executionContext) _DebugMessage_id(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_id(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_inputType(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_inputType(ctx, field) if err != nil { return graphql.Null } @@ -8181,7 +9733,7 @@ func (ec *executionContext) _DebugMessage_id(ctx context.Context, field graphql. }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.ID, nil + return obj.InputType, nil }) if err != nil { ec.Error(ctx, err) @@ -8195,24 +9747,24 @@ func (ec *executionContext) _DebugMessage_id(ctx context.Context, field graphql. } res := resTmp.(string) fc.Result = res - return ec.marshalNID2string(ctx, field.Selections, res) + return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_inputType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ID does not have child fields") + return nil, errors.New("field of type String does not have child fields") }, } return fc, nil } -func (ec *executionContext) _DebugMessage_createdAt(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_createdAt(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_isSearchSelectable(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_isSearchSelectable(ctx, field) if err != nil { return graphql.Null } @@ -8225,7 +9777,7 @@ func (ec *executionContext) _DebugMessage_createdAt(ctx context.Context, field g }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.CreatedAt, nil + return obj.IsSearchSelectable, nil }) if err != nil { ec.Error(ctx, err) @@ -8237,26 +9789,26 @@ func (ec *executionContext) _DebugMessage_createdAt(ctx context.Context, field g } return graphql.Null } - res := resTmp.(time.Time) + res := resTmp.(bool) fc.Result = res - return ec.marshalNISOTimestamp2timeᚐTime(ctx, field.Selections, res) + return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_createdAt(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_isSearchSelectable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ISOTimestamp does not have child fields") + return nil, errors.New("field of type Boolean does not have child fields") }, } return fc, nil } -func (ec *executionContext) _DebugMessage_updatedAt(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_updatedAt(ctx, field) +func (ec *executionContext) _DestinationFieldConfig_supportsValidation(ctx context.Context, field graphql.CollectedField, obj *DestinationFieldConfig) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationFieldConfig_supportsValidation(ctx, field) if err != nil { return graphql.Null } @@ -8269,7 +9821,7 @@ func (ec *executionContext) _DebugMessage_updatedAt(ctx context.Context, field g }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.UpdatedAt, nil + return obj.SupportsValidation, nil }) if err != nil { ec.Error(ctx, err) @@ -8281,26 +9833,26 @@ func (ec *executionContext) _DebugMessage_updatedAt(ctx context.Context, field g } return graphql.Null } - res := resTmp.(time.Time) + res := resTmp.(bool) fc.Result = res - return ec.marshalNISOTimestamp2timeᚐTime(ctx, field.Selections, res) + return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_updatedAt(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationFieldConfig_supportsValidation(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationFieldConfig", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ISOTimestamp does not have child fields") + return nil, errors.New("field of type Boolean does not have child fields") }, } return fc, nil } -func (ec *executionContext) _DebugMessage_type(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_type(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_type(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_type(ctx, field) if err != nil { return graphql.Null } @@ -8327,24 +9879,24 @@ func (ec *executionContext) _DebugMessage_type(ctx context.Context, field graphq } res := resTmp.(string) fc.Result = res - return ec.marshalNString2string(ctx, field.Selections, res) + return ec.marshalNDestinationType2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type String does not have child fields") + return nil, errors.New("field of type DestinationType does not have child fields") }, } return fc, nil } -func (ec *executionContext) _DebugMessage_status(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_status(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_name(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_name(ctx, field) if err != nil { return graphql.Null } @@ -8357,7 +9909,7 @@ func (ec *executionContext) _DebugMessage_status(ctx context.Context, field grap }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Status, nil + return obj.Name, nil }) if err != nil { ec.Error(ctx, err) @@ -8374,9 +9926,9 @@ func (ec *executionContext) _DebugMessage_status(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_status(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, @@ -8387,8 +9939,8 @@ func (ec *executionContext) fieldContext_DebugMessage_status(ctx context.Context return fc, nil } -func (ec *executionContext) _DebugMessage_userID(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_userID(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_iconURL(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_iconURL(ctx, field) if err != nil { return graphql.Null } @@ -8401,105 +9953,26 @@ func (ec *executionContext) _DebugMessage_userID(ctx context.Context, field grap }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.UserID, nil + return obj.IconURL, nil }) if err != nil { ec.Error(ctx, err) return graphql.Null } if resTmp == nil { - return graphql.Null - } - res := resTmp.(*string) - fc.Result = res - return ec.marshalOID2ᚖstring(ctx, field.Selections, res) -} - -func (ec *executionContext) fieldContext_DebugMessage_userID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { - fc = &graphql.FieldContext{ - Object: "DebugMessage", - Field: field, - IsMethod: false, - IsResolver: false, - Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ID does not have child fields") - }, - } - return fc, nil -} - -func (ec *executionContext) _DebugMessage_userName(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_userName(ctx, field) - if err != nil { - return graphql.Null - } - ctx = graphql.WithFieldContext(ctx, fc) - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { - ctx = rctx // use context from middleware stack in children - return obj.UserName, nil - }) - if err != nil { - ec.Error(ctx, err) - return graphql.Null - } - if resTmp == nil { - return graphql.Null - } - res := resTmp.(*string) - fc.Result = res - return ec.marshalOString2ᚖstring(ctx, field.Selections, res) -} - -func (ec *executionContext) fieldContext_DebugMessage_userName(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { - fc = &graphql.FieldContext{ - Object: "DebugMessage", - Field: field, - IsMethod: false, - IsResolver: false, - Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type String does not have child fields") - }, - } - return fc, nil -} - -func (ec *executionContext) _DebugMessage_source(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_source(ctx, field) - if err != nil { - return graphql.Null - } - ctx = graphql.WithFieldContext(ctx, fc) - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") } - }() - resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { - ctx = rctx // use context from middleware stack in children - return obj.Source, nil - }) - if err != nil { - ec.Error(ctx, err) return graphql.Null } - if resTmp == nil { - return graphql.Null - } - res := resTmp.(*string) + res := resTmp.(string) fc.Result = res - return ec.marshalOString2ᚖstring(ctx, field.Selections, res) + return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_source(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_iconURL(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, @@ -8510,8 +9983,8 @@ func (ec *executionContext) fieldContext_DebugMessage_source(ctx context.Context return fc, nil } -func (ec *executionContext) _DebugMessage_destination(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_destination(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_iconAltText(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_iconAltText(ctx, field) if err != nil { return graphql.Null } @@ -8524,7 +9997,7 @@ func (ec *executionContext) _DebugMessage_destination(ctx context.Context, field }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Destination, nil + return obj.IconAltText, nil }) if err != nil { ec.Error(ctx, err) @@ -8541,9 +10014,9 @@ func (ec *executionContext) _DebugMessage_destination(ctx context.Context, field return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_destination(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_iconAltText(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, @@ -8554,8 +10027,8 @@ func (ec *executionContext) fieldContext_DebugMessage_destination(ctx context.Co return fc, nil } -func (ec *executionContext) _DebugMessage_serviceID(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_serviceID(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_disabledMessage(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_disabledMessage(ctx, field) if err != nil { return graphql.Null } @@ -8568,64 +10041,26 @@ func (ec *executionContext) _DebugMessage_serviceID(ctx context.Context, field g }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.ServiceID, nil + return obj.DisabledMessage, nil }) if err != nil { ec.Error(ctx, err) return graphql.Null } if resTmp == nil { - return graphql.Null - } - res := resTmp.(*string) - fc.Result = res - return ec.marshalOID2ᚖstring(ctx, field.Selections, res) -} - -func (ec *executionContext) fieldContext_DebugMessage_serviceID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { - fc = &graphql.FieldContext{ - Object: "DebugMessage", - Field: field, - IsMethod: false, - IsResolver: false, - Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ID does not have child fields") - }, - } - return fc, nil -} - -func (ec *executionContext) _DebugMessage_serviceName(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_serviceName(ctx, field) - if err != nil { - return graphql.Null - } - ctx = graphql.WithFieldContext(ctx, fc) - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") } - }() - resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { - ctx = rctx // use context from middleware stack in children - return obj.ServiceName, nil - }) - if err != nil { - ec.Error(ctx, err) - return graphql.Null - } - if resTmp == nil { return graphql.Null } - res := resTmp.(*string) + res := resTmp.(string) fc.Result = res - return ec.marshalOString2ᚖstring(ctx, field.Selections, res) + return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_serviceName(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_disabledMessage(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, @@ -8636,49 +10071,8 @@ func (ec *executionContext) fieldContext_DebugMessage_serviceName(ctx context.Co return fc, nil } -func (ec *executionContext) _DebugMessage_alertID(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_alertID(ctx, field) - if err != nil { - return graphql.Null - } - ctx = graphql.WithFieldContext(ctx, fc) - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { - ctx = rctx // use context from middleware stack in children - return obj.AlertID, nil - }) - if err != nil { - ec.Error(ctx, err) - return graphql.Null - } - if resTmp == nil { - return graphql.Null - } - res := resTmp.(*int) - fc.Result = res - return ec.marshalOInt2ᚖint(ctx, field.Selections, res) -} - -func (ec *executionContext) fieldContext_DebugMessage_alertID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { - fc = &graphql.FieldContext{ - Object: "DebugMessage", - Field: field, - IsMethod: false, - IsResolver: false, - Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type Int does not have child fields") - }, - } - return fc, nil -} - -func (ec *executionContext) _DebugMessage_providerID(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_providerID(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_enabled(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_enabled(ctx, field) if err != nil { return graphql.Null } @@ -8691,76 +10085,38 @@ func (ec *executionContext) _DebugMessage_providerID(ctx context.Context, field }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.ProviderID, nil + return obj.Enabled, nil }) if err != nil { ec.Error(ctx, err) return graphql.Null } if resTmp == nil { - return graphql.Null - } - res := resTmp.(*string) - fc.Result = res - return ec.marshalOID2ᚖstring(ctx, field.Selections, res) -} - -func (ec *executionContext) fieldContext_DebugMessage_providerID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { - fc = &graphql.FieldContext{ - Object: "DebugMessage", - Field: field, - IsMethod: false, - IsResolver: false, - Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ID does not have child fields") - }, - } - return fc, nil -} - -func (ec *executionContext) _DebugMessage_sentAt(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_sentAt(ctx, field) - if err != nil { - return graphql.Null - } - ctx = graphql.WithFieldContext(ctx, fc) - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") } - }() - resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { - ctx = rctx // use context from middleware stack in children - return obj.SentAt, nil - }) - if err != nil { - ec.Error(ctx, err) - return graphql.Null - } - if resTmp == nil { return graphql.Null } - res := resTmp.(*time.Time) + res := resTmp.(bool) fc.Result = res - return ec.marshalOISOTimestamp2ᚖtimeᚐTime(ctx, field.Selections, res) + return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_sentAt(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_enabled(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ISOTimestamp does not have child fields") + return nil, errors.New("field of type Boolean does not have child fields") }, } return fc, nil } -func (ec *executionContext) _DebugMessage_retryCount(ctx context.Context, field graphql.CollectedField, obj *DebugMessage) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessage_retryCount(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_requiredFields(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_requiredFields(ctx, field) if err != nil { return graphql.Null } @@ -8773,7 +10129,7 @@ func (ec *executionContext) _DebugMessage_retryCount(ctx context.Context, field }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.RetryCount, nil + return obj.RequiredFields, nil }) if err != nil { ec.Error(ctx, err) @@ -8785,26 +10141,48 @@ func (ec *executionContext) _DebugMessage_retryCount(ctx context.Context, field } return graphql.Null } - res := resTmp.(int) + res := resTmp.([]DestinationFieldConfig) fc.Result = res - return ec.marshalNInt2int(ctx, field.Selections, res) + return ec.marshalNDestinationFieldConfig2ᚕgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationFieldConfigᚄ(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessage_retryCount(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_requiredFields(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessage", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type Int does not have child fields") + switch field.Name { + case "fieldID": + return ec.fieldContext_DestinationFieldConfig_fieldID(ctx, field) + case "labelSingular": + return ec.fieldContext_DestinationFieldConfig_labelSingular(ctx, field) + case "labelPlural": + return ec.fieldContext_DestinationFieldConfig_labelPlural(ctx, field) + case "hint": + return ec.fieldContext_DestinationFieldConfig_hint(ctx, field) + case "hintURL": + return ec.fieldContext_DestinationFieldConfig_hintURL(ctx, field) + case "placeholderText": + return ec.fieldContext_DestinationFieldConfig_placeholderText(ctx, field) + case "prefix": + return ec.fieldContext_DestinationFieldConfig_prefix(ctx, field) + case "inputType": + return ec.fieldContext_DestinationFieldConfig_inputType(ctx, field) + case "isSearchSelectable": + return ec.fieldContext_DestinationFieldConfig_isSearchSelectable(ctx, field) + case "supportsValidation": + return ec.fieldContext_DestinationFieldConfig_supportsValidation(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type DestinationFieldConfig", field.Name) }, } return fc, nil } -func (ec *executionContext) _DebugMessageStatusInfo_state(ctx context.Context, field graphql.CollectedField, obj *DebugMessageStatusInfo) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugMessageStatusInfo_state(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_userDisclaimer(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_userDisclaimer(ctx, field) if err != nil { return graphql.Null } @@ -8817,7 +10195,7 @@ func (ec *executionContext) _DebugMessageStatusInfo_state(ctx context.Context, f }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.State, nil + return obj.UserDisclaimer, nil }) if err != nil { ec.Error(ctx, err) @@ -8829,34 +10207,26 @@ func (ec *executionContext) _DebugMessageStatusInfo_state(ctx context.Context, f } return graphql.Null } - res := resTmp.(*NotificationState) + res := resTmp.(string) fc.Result = res - return ec.marshalNNotificationState2ᚖgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐNotificationState(ctx, field.Selections, res) + return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugMessageStatusInfo_state(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_userDisclaimer(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugMessageStatusInfo", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - switch field.Name { - case "details": - return ec.fieldContext_NotificationState_details(ctx, field) - case "status": - return ec.fieldContext_NotificationState_status(ctx, field) - case "formattedSrcValue": - return ec.fieldContext_NotificationState_formattedSrcValue(ctx, field) - } - return nil, fmt.Errorf("no field named %q was found under type NotificationState", field.Name) + return nil, errors.New("field of type String does not have child fields") }, } return fc, nil } -func (ec *executionContext) _DebugSendSMSInfo_id(ctx context.Context, field graphql.CollectedField, obj *DebugSendSMSInfo) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugSendSMSInfo_id(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_isContactMethod(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_isContactMethod(ctx, field) if err != nil { return graphql.Null } @@ -8869,7 +10239,7 @@ func (ec *executionContext) _DebugSendSMSInfo_id(ctx context.Context, field grap }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.ID, nil + return obj.IsContactMethod, nil }) if err != nil { ec.Error(ctx, err) @@ -8881,26 +10251,26 @@ func (ec *executionContext) _DebugSendSMSInfo_id(ctx context.Context, field grap } return graphql.Null } - res := resTmp.(string) + res := resTmp.(bool) fc.Result = res - return ec.marshalNID2string(ctx, field.Selections, res) + return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugSendSMSInfo_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_isContactMethod(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugSendSMSInfo", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type ID does not have child fields") + return nil, errors.New("field of type Boolean does not have child fields") }, } return fc, nil } -func (ec *executionContext) _DebugSendSMSInfo_providerURL(ctx context.Context, field graphql.CollectedField, obj *DebugSendSMSInfo) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugSendSMSInfo_providerURL(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_isEPTarget(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_isEPTarget(ctx, field) if err != nil { return graphql.Null } @@ -8913,7 +10283,7 @@ func (ec *executionContext) _DebugSendSMSInfo_providerURL(ctx context.Context, f }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.ProviderURL, nil + return obj.IsEPTarget, nil }) if err != nil { ec.Error(ctx, err) @@ -8925,26 +10295,26 @@ func (ec *executionContext) _DebugSendSMSInfo_providerURL(ctx context.Context, f } return graphql.Null } - res := resTmp.(string) + res := resTmp.(bool) fc.Result = res - return ec.marshalNString2string(ctx, field.Selections, res) + return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugSendSMSInfo_providerURL(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_isEPTarget(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugSendSMSInfo", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type String does not have child fields") + return nil, errors.New("field of type Boolean does not have child fields") }, } return fc, nil } -func (ec *executionContext) _DebugSendSMSInfo_fromNumber(ctx context.Context, field graphql.CollectedField, obj *DebugSendSMSInfo) (ret graphql.Marshaler) { - fc, err := ec.fieldContext_DebugSendSMSInfo_fromNumber(ctx, field) +func (ec *executionContext) _DestinationTypeInfo_isSchedOnCallNotify(ctx context.Context, field graphql.CollectedField, obj *DestinationTypeInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DestinationTypeInfo_isSchedOnCallNotify(ctx, field) if err != nil { return graphql.Null } @@ -8957,7 +10327,7 @@ func (ec *executionContext) _DebugSendSMSInfo_fromNumber(ctx context.Context, fi }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.FromNumber, nil + return obj.IsSchedOnCallNotify, nil }) if err != nil { ec.Error(ctx, err) @@ -8969,19 +10339,19 @@ func (ec *executionContext) _DebugSendSMSInfo_fromNumber(ctx context.Context, fi } return graphql.Null } - res := resTmp.(string) + res := resTmp.(bool) fc.Result = res - return ec.marshalNString2string(ctx, field.Selections, res) + return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) fieldContext_DebugSendSMSInfo_fromNumber(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { +func (ec *executionContext) fieldContext_DestinationTypeInfo_isSchedOnCallNotify(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { fc = &graphql.FieldContext{ - Object: "DebugSendSMSInfo", + Object: "DestinationTypeInfo", Field: field, IsMethod: false, IsResolver: false, Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { - return nil, errors.New("field of type String does not have child fields") + return nil, errors.New("field of type Boolean does not have child fields") }, } return fc, nil @@ -9722,6 +11092,94 @@ func (ec *executionContext) fieldContext_EscalationPolicyStep_escalationPolicy(c return fc, nil } +func (ec *executionContext) _FieldValuePair_fieldID(ctx context.Context, field graphql.CollectedField, obj *FieldValuePair) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_FieldValuePair_fieldID(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.FieldID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_FieldValuePair_fieldID(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "FieldValuePair", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _FieldValuePair_value(ctx context.Context, field graphql.CollectedField, obj *FieldValuePair) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_FieldValuePair_value(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Value, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_FieldValuePair_value(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "FieldValuePair", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _GQLAPIKey_id(ctx context.Context, field graphql.CollectedField, obj *GQLAPIKey) (ret graphql.Marshaler) { fc, err := ec.fieldContext_GQLAPIKey_id(ctx, field) if err != nil { @@ -18538,6 +19996,129 @@ func (ec *executionContext) fieldContext_Query_swoStatus(ctx context.Context, fi return fc, nil } +func (ec *executionContext) _Query_destinationTypes(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_destinationTypes(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().DestinationTypes(rctx) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]DestinationTypeInfo) + fc.Result = res + return ec.marshalNDestinationTypeInfo2ᚕgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationTypeInfoᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_destinationTypes(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "type": + return ec.fieldContext_DestinationTypeInfo_type(ctx, field) + case "name": + return ec.fieldContext_DestinationTypeInfo_name(ctx, field) + case "iconURL": + return ec.fieldContext_DestinationTypeInfo_iconURL(ctx, field) + case "iconAltText": + return ec.fieldContext_DestinationTypeInfo_iconAltText(ctx, field) + case "disabledMessage": + return ec.fieldContext_DestinationTypeInfo_disabledMessage(ctx, field) + case "enabled": + return ec.fieldContext_DestinationTypeInfo_enabled(ctx, field) + case "requiredFields": + return ec.fieldContext_DestinationTypeInfo_requiredFields(ctx, field) + case "userDisclaimer": + return ec.fieldContext_DestinationTypeInfo_userDisclaimer(ctx, field) + case "isContactMethod": + return ec.fieldContext_DestinationTypeInfo_isContactMethod(ctx, field) + case "isEPTarget": + return ec.fieldContext_DestinationTypeInfo_isEPTarget(ctx, field) + case "isSchedOnCallNotify": + return ec.fieldContext_DestinationTypeInfo_isSchedOnCallNotify(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type DestinationTypeInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _Query_destinationFieldValidate(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_destinationFieldValidate(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().DestinationFieldValidate(rctx, fc.Args["input"].(DestinationFieldValidateInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(bool) + fc.Result = res + return ec.marshalNBoolean2bool(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_destinationFieldValidate(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_destinationFieldValidate_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + func (ec *executionContext) _Query_gqlAPIKeys(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { fc, err := ec.fieldContext_Query_gqlAPIKeys(ctx, field) if err != nil { @@ -29206,6 +30787,81 @@ func (ec *executionContext) unmarshalInputDebugSendSMSInput(ctx context.Context, return it, nil } +func (ec *executionContext) unmarshalInputDestinationFieldValidateInput(ctx context.Context, obj interface{}) (DestinationFieldValidateInput, error) { + var it DestinationFieldValidateInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"destType", "fieldID", "value"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "destType": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("destType")) + data, err := ec.unmarshalNDestinationType2string(ctx, v) + if err != nil { + return it, err + } + it.DestType = data + case "fieldID": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("fieldID")) + data, err := ec.unmarshalNID2string(ctx, v) + if err != nil { + return it, err + } + it.FieldID = data + case "value": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("value")) + data, err := ec.unmarshalNString2string(ctx, v) + if err != nil { + return it, err + } + it.Value = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputDestinationInput(ctx context.Context, obj interface{}) (DestinationInput, error) { + var it DestinationInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"type", "values"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "type": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("type")) + data, err := ec.unmarshalNDestinationType2string(ctx, v) + if err != nil { + return it, err + } + it.Type = data + case "values": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("values")) + data, err := ec.unmarshalNFieldValueInput2ᚕgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐFieldValueInputᚄ(ctx, v) + if err != nil { + return it, err + } + it.Values = data + } + } + + return it, nil +} + func (ec *executionContext) unmarshalInputEscalationPolicySearchOptions(ctx context.Context, obj interface{}) (EscalationPolicySearchOptions, error) { var it EscalationPolicySearchOptions asMap := map[string]interface{}{} @@ -29284,6 +30940,40 @@ func (ec *executionContext) unmarshalInputEscalationPolicySearchOptions(ctx cont return it, nil } +func (ec *executionContext) unmarshalInputFieldValueInput(ctx context.Context, obj interface{}) (FieldValueInput, error) { + var it FieldValueInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"fieldID", "value"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "fieldID": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("fieldID")) + data, err := ec.unmarshalNID2string(ctx, v) + if err != nil { + return it, err + } + it.FieldID = data + case "value": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("value")) + data, err := ec.unmarshalNString2string(ctx, v) + if err != nil { + return it, err + } + it.Value = data + } + } + + return it, nil +} + func (ec *executionContext) unmarshalInputIntegrationKeySearchOptions(ctx context.Context, obj interface{}) (IntegrationKeySearchOptions, error) { var it IntegrationKeySearchOptions asMap := map[string]interface{}{} @@ -32468,24 +34158,163 @@ func (ec *executionContext) _ConfigValue(ctx context.Context, sel ast.SelectionS return out } -var createdGQLAPIKeyImplementors = []string{"CreatedGQLAPIKey"} +var createdGQLAPIKeyImplementors = []string{"CreatedGQLAPIKey"} + +func (ec *executionContext) _CreatedGQLAPIKey(ctx context.Context, sel ast.SelectionSet, obj *CreatedGQLAPIKey) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, createdGQLAPIKeyImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("CreatedGQLAPIKey") + case "id": + out.Values[i] = ec._CreatedGQLAPIKey_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "token": + out.Values[i] = ec._CreatedGQLAPIKey_token(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var debugCarrierInfoImplementors = []string{"DebugCarrierInfo"} + +func (ec *executionContext) _DebugCarrierInfo(ctx context.Context, sel ast.SelectionSet, obj *twilio.CarrierInfo) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, debugCarrierInfoImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("DebugCarrierInfo") + case "name": + out.Values[i] = ec._DebugCarrierInfo_name(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "type": + out.Values[i] = ec._DebugCarrierInfo_type(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "mobileNetworkCode": + out.Values[i] = ec._DebugCarrierInfo_mobileNetworkCode(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "mobileCountryCode": + out.Values[i] = ec._DebugCarrierInfo_mobileCountryCode(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var debugMessageImplementors = []string{"DebugMessage"} -func (ec *executionContext) _CreatedGQLAPIKey(ctx context.Context, sel ast.SelectionSet, obj *CreatedGQLAPIKey) graphql.Marshaler { - fields := graphql.CollectFields(ec.OperationContext, sel, createdGQLAPIKeyImplementors) +func (ec *executionContext) _DebugMessage(ctx context.Context, sel ast.SelectionSet, obj *DebugMessage) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, debugMessageImplementors) out := graphql.NewFieldSet(fields) deferred := make(map[string]*graphql.FieldSet) for i, field := range fields { switch field.Name { case "__typename": - out.Values[i] = graphql.MarshalString("CreatedGQLAPIKey") + out.Values[i] = graphql.MarshalString("DebugMessage") case "id": - out.Values[i] = ec._CreatedGQLAPIKey_id(ctx, field, obj) + out.Values[i] = ec._DebugMessage_id(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } - case "token": - out.Values[i] = ec._CreatedGQLAPIKey_token(ctx, field, obj) + case "createdAt": + out.Values[i] = ec._DebugMessage_createdAt(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updatedAt": + out.Values[i] = ec._DebugMessage_updatedAt(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "type": + out.Values[i] = ec._DebugMessage_type(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "status": + out.Values[i] = ec._DebugMessage_status(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "userID": + out.Values[i] = ec._DebugMessage_userID(ctx, field, obj) + case "userName": + out.Values[i] = ec._DebugMessage_userName(ctx, field, obj) + case "source": + out.Values[i] = ec._DebugMessage_source(ctx, field, obj) + case "destination": + out.Values[i] = ec._DebugMessage_destination(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "serviceID": + out.Values[i] = ec._DebugMessage_serviceID(ctx, field, obj) + case "serviceName": + out.Values[i] = ec._DebugMessage_serviceName(ctx, field, obj) + case "alertID": + out.Values[i] = ec._DebugMessage_alertID(ctx, field, obj) + case "providerID": + out.Values[i] = ec._DebugMessage_providerID(ctx, field, obj) + case "sentAt": + out.Values[i] = ec._DebugMessage_sentAt(ctx, field, obj) + case "retryCount": + out.Values[i] = ec._DebugMessage_retryCount(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } @@ -32512,34 +34341,19 @@ func (ec *executionContext) _CreatedGQLAPIKey(ctx context.Context, sel ast.Selec return out } -var debugCarrierInfoImplementors = []string{"DebugCarrierInfo"} +var debugMessageStatusInfoImplementors = []string{"DebugMessageStatusInfo"} -func (ec *executionContext) _DebugCarrierInfo(ctx context.Context, sel ast.SelectionSet, obj *twilio.CarrierInfo) graphql.Marshaler { - fields := graphql.CollectFields(ec.OperationContext, sel, debugCarrierInfoImplementors) +func (ec *executionContext) _DebugMessageStatusInfo(ctx context.Context, sel ast.SelectionSet, obj *DebugMessageStatusInfo) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, debugMessageStatusInfoImplementors) out := graphql.NewFieldSet(fields) deferred := make(map[string]*graphql.FieldSet) for i, field := range fields { switch field.Name { case "__typename": - out.Values[i] = graphql.MarshalString("DebugCarrierInfo") - case "name": - out.Values[i] = ec._DebugCarrierInfo_name(ctx, field, obj) - if out.Values[i] == graphql.Null { - out.Invalids++ - } - case "type": - out.Values[i] = ec._DebugCarrierInfo_type(ctx, field, obj) - if out.Values[i] == graphql.Null { - out.Invalids++ - } - case "mobileNetworkCode": - out.Values[i] = ec._DebugCarrierInfo_mobileNetworkCode(ctx, field, obj) - if out.Values[i] == graphql.Null { - out.Invalids++ - } - case "mobileCountryCode": - out.Values[i] = ec._DebugCarrierInfo_mobileCountryCode(ctx, field, obj) + out.Values[i] = graphql.MarshalString("DebugMessageStatusInfo") + case "state": + out.Values[i] = ec._DebugMessageStatusInfo_state(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } @@ -32566,65 +34380,78 @@ func (ec *executionContext) _DebugCarrierInfo(ctx context.Context, sel ast.Selec return out } -var debugMessageImplementors = []string{"DebugMessage"} +var debugSendSMSInfoImplementors = []string{"DebugSendSMSInfo"} -func (ec *executionContext) _DebugMessage(ctx context.Context, sel ast.SelectionSet, obj *DebugMessage) graphql.Marshaler { - fields := graphql.CollectFields(ec.OperationContext, sel, debugMessageImplementors) +func (ec *executionContext) _DebugSendSMSInfo(ctx context.Context, sel ast.SelectionSet, obj *DebugSendSMSInfo) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, debugSendSMSInfoImplementors) out := graphql.NewFieldSet(fields) deferred := make(map[string]*graphql.FieldSet) for i, field := range fields { switch field.Name { case "__typename": - out.Values[i] = graphql.MarshalString("DebugMessage") + out.Values[i] = graphql.MarshalString("DebugSendSMSInfo") case "id": - out.Values[i] = ec._DebugMessage_id(ctx, field, obj) + out.Values[i] = ec._DebugSendSMSInfo_id(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } - case "createdAt": - out.Values[i] = ec._DebugMessage_createdAt(ctx, field, obj) + case "providerURL": + out.Values[i] = ec._DebugSendSMSInfo_providerURL(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } - case "updatedAt": - out.Values[i] = ec._DebugMessage_updatedAt(ctx, field, obj) + case "fromNumber": + out.Values[i] = ec._DebugSendSMSInfo_fromNumber(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var destinationImplementors = []string{"Destination"} + +func (ec *executionContext) _Destination(ctx context.Context, sel ast.SelectionSet, obj *Destination) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, destinationImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Destination") case "type": - out.Values[i] = ec._DebugMessage_type(ctx, field, obj) + out.Values[i] = ec._Destination_type(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } - case "status": - out.Values[i] = ec._DebugMessage_status(ctx, field, obj) + case "values": + out.Values[i] = ec._Destination_values(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } - case "userID": - out.Values[i] = ec._DebugMessage_userID(ctx, field, obj) - case "userName": - out.Values[i] = ec._DebugMessage_userName(ctx, field, obj) - case "source": - out.Values[i] = ec._DebugMessage_source(ctx, field, obj) - case "destination": - out.Values[i] = ec._DebugMessage_destination(ctx, field, obj) - if out.Values[i] == graphql.Null { - out.Invalids++ - } - case "serviceID": - out.Values[i] = ec._DebugMessage_serviceID(ctx, field, obj) - case "serviceName": - out.Values[i] = ec._DebugMessage_serviceName(ctx, field, obj) - case "alertID": - out.Values[i] = ec._DebugMessage_alertID(ctx, field, obj) - case "providerID": - out.Values[i] = ec._DebugMessage_providerID(ctx, field, obj) - case "sentAt": - out.Values[i] = ec._DebugMessage_sentAt(ctx, field, obj) - case "retryCount": - out.Values[i] = ec._DebugMessage_retryCount(ctx, field, obj) + case "typeInfo": + out.Values[i] = ec._Destination_typeInfo(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } @@ -32651,19 +34478,64 @@ func (ec *executionContext) _DebugMessage(ctx context.Context, sel ast.Selection return out } -var debugMessageStatusInfoImplementors = []string{"DebugMessageStatusInfo"} +var destinationFieldConfigImplementors = []string{"DestinationFieldConfig"} -func (ec *executionContext) _DebugMessageStatusInfo(ctx context.Context, sel ast.SelectionSet, obj *DebugMessageStatusInfo) graphql.Marshaler { - fields := graphql.CollectFields(ec.OperationContext, sel, debugMessageStatusInfoImplementors) +func (ec *executionContext) _DestinationFieldConfig(ctx context.Context, sel ast.SelectionSet, obj *DestinationFieldConfig) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, destinationFieldConfigImplementors) out := graphql.NewFieldSet(fields) deferred := make(map[string]*graphql.FieldSet) for i, field := range fields { switch field.Name { case "__typename": - out.Values[i] = graphql.MarshalString("DebugMessageStatusInfo") - case "state": - out.Values[i] = ec._DebugMessageStatusInfo_state(ctx, field, obj) + out.Values[i] = graphql.MarshalString("DestinationFieldConfig") + case "fieldID": + out.Values[i] = ec._DestinationFieldConfig_fieldID(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "labelSingular": + out.Values[i] = ec._DestinationFieldConfig_labelSingular(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "labelPlural": + out.Values[i] = ec._DestinationFieldConfig_labelPlural(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "hint": + out.Values[i] = ec._DestinationFieldConfig_hint(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "hintURL": + out.Values[i] = ec._DestinationFieldConfig_hintURL(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "placeholderText": + out.Values[i] = ec._DestinationFieldConfig_placeholderText(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "prefix": + out.Values[i] = ec._DestinationFieldConfig_prefix(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "inputType": + out.Values[i] = ec._DestinationFieldConfig_inputType(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "isSearchSelectable": + out.Values[i] = ec._DestinationFieldConfig_isSearchSelectable(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "supportsValidation": + out.Values[i] = ec._DestinationFieldConfig_supportsValidation(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } @@ -32690,29 +34562,69 @@ func (ec *executionContext) _DebugMessageStatusInfo(ctx context.Context, sel ast return out } -var debugSendSMSInfoImplementors = []string{"DebugSendSMSInfo"} +var destinationTypeInfoImplementors = []string{"DestinationTypeInfo"} -func (ec *executionContext) _DebugSendSMSInfo(ctx context.Context, sel ast.SelectionSet, obj *DebugSendSMSInfo) graphql.Marshaler { - fields := graphql.CollectFields(ec.OperationContext, sel, debugSendSMSInfoImplementors) +func (ec *executionContext) _DestinationTypeInfo(ctx context.Context, sel ast.SelectionSet, obj *DestinationTypeInfo) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, destinationTypeInfoImplementors) out := graphql.NewFieldSet(fields) deferred := make(map[string]*graphql.FieldSet) for i, field := range fields { switch field.Name { case "__typename": - out.Values[i] = graphql.MarshalString("DebugSendSMSInfo") - case "id": - out.Values[i] = ec._DebugSendSMSInfo_id(ctx, field, obj) + out.Values[i] = graphql.MarshalString("DestinationTypeInfo") + case "type": + out.Values[i] = ec._DestinationTypeInfo_type(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } - case "providerURL": - out.Values[i] = ec._DebugSendSMSInfo_providerURL(ctx, field, obj) + case "name": + out.Values[i] = ec._DestinationTypeInfo_name(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } - case "fromNumber": - out.Values[i] = ec._DebugSendSMSInfo_fromNumber(ctx, field, obj) + case "iconURL": + out.Values[i] = ec._DestinationTypeInfo_iconURL(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "iconAltText": + out.Values[i] = ec._DestinationTypeInfo_iconAltText(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "disabledMessage": + out.Values[i] = ec._DestinationTypeInfo_disabledMessage(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "enabled": + out.Values[i] = ec._DestinationTypeInfo_enabled(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "requiredFields": + out.Values[i] = ec._DestinationTypeInfo_requiredFields(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "userDisclaimer": + out.Values[i] = ec._DestinationTypeInfo_userDisclaimer(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "isContactMethod": + out.Values[i] = ec._DestinationTypeInfo_isContactMethod(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "isEPTarget": + out.Values[i] = ec._DestinationTypeInfo_isEPTarget(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "isSchedOnCallNotify": + out.Values[i] = ec._DestinationTypeInfo_isSchedOnCallNotify(ctx, field, obj) if out.Values[i] == graphql.Null { out.Invalids++ } @@ -33043,39 +34955,83 @@ func (ec *executionContext) _EscalationPolicyStep(ctx context.Context, sel ast.S } out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) - case "escalationPolicy": - field := field + case "escalationPolicy": + field := field + + innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._EscalationPolicyStep_escalationPolicy(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } - innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - } - }() - res = ec._EscalationPolicyStep_escalationPolicy(ctx, field, obj) - return res - } + atomic.AddInt32(&ec.deferred, int32(len(deferred))) - if field.Deferrable != nil { - dfs, ok := deferred[field.Deferrable.Label] - di := 0 - if ok { - dfs.AddField(field) - di = len(dfs.Values) - 1 - } else { - dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) - deferred[field.Deferrable.Label] = dfs - } - dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { - return innerFunc(ctx, dfs) - }) + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } - // don't run the out.Concurrently() call below - out.Values[i] = graphql.Null - continue - } + return out +} - out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) +var fieldValuePairImplementors = []string{"FieldValuePair"} + +func (ec *executionContext) _FieldValuePair(ctx context.Context, sel ast.SelectionSet, obj *FieldValuePair) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, fieldValuePairImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("FieldValuePair") + case "fieldID": + out.Values[i] = ec._FieldValuePair_fieldID(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "value": + out.Values[i] = ec._FieldValuePair_value(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -35489,6 +37445,50 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) } + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "destinationTypes": + field := field + + innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_destinationTypes(ctx, field) + if res == graphql.Null { + atomic.AddUint32(&fs.Invalids, 1) + } + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "destinationFieldValidate": + field := field + + innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_destinationFieldValidate(ctx, field) + if res == graphql.Null { + atomic.AddUint32(&fs.Invalids, 1) + } + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) case "gqlAPIKeys": field := field @@ -39655,6 +41655,132 @@ func (ec *executionContext) unmarshalNDebugSendSMSInput2githubᚗcomᚋtargetᚋ return res, graphql.ErrorOnPath(ctx, err) } +func (ec *executionContext) marshalNDestinationFieldConfig2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationFieldConfig(ctx context.Context, sel ast.SelectionSet, v DestinationFieldConfig) graphql.Marshaler { + return ec._DestinationFieldConfig(ctx, sel, &v) +} + +func (ec *executionContext) marshalNDestinationFieldConfig2ᚕgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationFieldConfigᚄ(ctx context.Context, sel ast.SelectionSet, v []DestinationFieldConfig) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalNDestinationFieldConfig2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationFieldConfig(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) unmarshalNDestinationFieldValidateInput2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationFieldValidateInput(ctx context.Context, v interface{}) (DestinationFieldValidateInput, error) { + res, err := ec.unmarshalInputDestinationFieldValidateInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalNDestinationType2string(ctx context.Context, v interface{}) (string, error) { + res, err := graphql.UnmarshalString(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNDestinationType2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { + res := graphql.MarshalString(v) + if res == graphql.Null { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + } + return res +} + +func (ec *executionContext) marshalNDestinationTypeInfo2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationTypeInfo(ctx context.Context, sel ast.SelectionSet, v DestinationTypeInfo) graphql.Marshaler { + return ec._DestinationTypeInfo(ctx, sel, &v) +} + +func (ec *executionContext) marshalNDestinationTypeInfo2ᚕgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationTypeInfoᚄ(ctx context.Context, sel ast.SelectionSet, v []DestinationTypeInfo) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalNDestinationTypeInfo2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationTypeInfo(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) marshalNDestinationTypeInfo2ᚖgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐDestinationTypeInfo(ctx context.Context, sel ast.SelectionSet, v *DestinationTypeInfo) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._DestinationTypeInfo(ctx, sel, v) +} + func (ec *executionContext) marshalNEscalationPolicy2githubᚗcomᚋtargetᚋgoalertᚋescalationᚐPolicy(ctx context.Context, sel ast.SelectionSet, v escalation.Policy) graphql.Marshaler { return ec._EscalationPolicy(ctx, sel, &v) } @@ -39765,6 +41891,76 @@ func (ec *executionContext) marshalNEscalationPolicyStep2ᚕgithubᚗcomᚋtarge return ret } +func (ec *executionContext) unmarshalNFieldValueInput2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐFieldValueInput(ctx context.Context, v interface{}) (FieldValueInput, error) { + res, err := ec.unmarshalInputFieldValueInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalNFieldValueInput2ᚕgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐFieldValueInputᚄ(ctx context.Context, v interface{}) ([]FieldValueInput, error) { + var vSlice []interface{} + if v != nil { + vSlice = graphql.CoerceList(v) + } + var err error + res := make([]FieldValueInput, len(vSlice)) + for i := range vSlice { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) + res[i], err = ec.unmarshalNFieldValueInput2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐFieldValueInput(ctx, vSlice[i]) + if err != nil { + return nil, err + } + } + return res, nil +} + +func (ec *executionContext) marshalNFieldValuePair2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐFieldValuePair(ctx context.Context, sel ast.SelectionSet, v FieldValuePair) graphql.Marshaler { + return ec._FieldValuePair(ctx, sel, &v) +} + +func (ec *executionContext) marshalNFieldValuePair2ᚕgithubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐFieldValuePairᚄ(ctx context.Context, sel ast.SelectionSet, v []FieldValuePair) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalNFieldValuePair2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐFieldValuePair(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + func (ec *executionContext) marshalNGQLAPIKey2githubᚗcomᚋtargetᚋgoalertᚋgraphql2ᚐGQLAPIKey(ctx context.Context, sel ast.SelectionSet, v GQLAPIKey) graphql.Marshaler { return ec._GQLAPIKey(ctx, sel, &v) } diff --git a/graphql2/models_gen.go b/graphql2/models_gen.go index 158277c60a..67bbab8105 100644 --- a/graphql2/models_gen.go +++ b/graphql2/models_gen.go @@ -291,6 +291,50 @@ type DebugSendSMSInput struct { Body string `json:"body"` } +type Destination struct { + Type string `json:"type"` + Values []FieldValuePair `json:"values"` + TypeInfo *DestinationTypeInfo `json:"typeInfo"` +} + +type DestinationFieldConfig struct { + FieldID string `json:"fieldID"` + LabelSingular string `json:"labelSingular"` + LabelPlural string `json:"labelPlural"` + Hint string `json:"hint"` + HintURL string `json:"hintURL"` + PlaceholderText string `json:"placeholderText"` + Prefix string `json:"prefix"` + InputType string `json:"inputType"` + IsSearchSelectable bool `json:"isSearchSelectable"` + SupportsValidation bool `json:"supportsValidation"` +} + +type DestinationFieldValidateInput struct { + DestType string `json:"destType"` + FieldID string `json:"fieldID"` + Value string `json:"value"` +} + +type DestinationInput struct { + Type string `json:"type"` + Values []FieldValueInput `json:"values"` +} + +type DestinationTypeInfo struct { + Type string `json:"type"` + Name string `json:"name"` + IconURL string `json:"iconURL"` + IconAltText string `json:"iconAltText"` + DisabledMessage string `json:"disabledMessage"` + Enabled bool `json:"enabled"` + RequiredFields []DestinationFieldConfig `json:"requiredFields"` + UserDisclaimer string `json:"userDisclaimer"` + IsContactMethod bool `json:"isContactMethod"` + IsEPTarget bool `json:"isEPTarget"` + IsSchedOnCallNotify bool `json:"isSchedOnCallNotify"` +} + type EscalationPolicyConnection struct { Nodes []escalation.Policy `json:"nodes"` PageInfo *PageInfo `json:"pageInfo"` @@ -305,6 +349,16 @@ type EscalationPolicySearchOptions struct { FavoritesFirst *bool `json:"favoritesFirst,omitempty"` } +type FieldValueInput struct { + FieldID string `json:"fieldID"` + Value string `json:"value"` +} + +type FieldValuePair struct { + FieldID string `json:"fieldID"` + Value string `json:"value"` +} + type GQLAPIKey struct { ID string `json:"id"` Name string `json:"name"` diff --git a/web/src/expflag.d.ts b/web/src/expflag.d.ts index c8c02252f1..136d300416 100644 --- a/web/src/expflag.d.ts +++ b/web/src/expflag.d.ts @@ -1,3 +1,3 @@ // Code generated by expflag/cmd/tsgen DO NOT EDIT. -type ExpFlag = 'example' | 'gql-api-keys' +type ExpFlag = 'dest-types' | 'example' | 'gql-api-keys' diff --git a/web/src/schema.d.ts b/web/src/schema.d.ts index 1415e7daf8..6c1e0351e7 100644 --- a/web/src/schema.d.ts +++ b/web/src/schema.d.ts @@ -339,6 +339,52 @@ export interface DebugSendSMSInput { to: string } +export interface Destination { + type: DestinationType + typeInfo: DestinationTypeInfo + values: FieldValuePair[] +} + +export interface DestinationFieldConfig { + fieldID: string + hint: string + hintURL: string + inputType: string + isSearchSelectable: boolean + labelPlural: string + labelSingular: string + placeholderText: string + prefix: string + supportsValidation: boolean +} + +export interface DestinationFieldValidateInput { + destType: DestinationType + fieldID: string + value: string +} + +export interface DestinationInput { + type: DestinationType + values: FieldValueInput[] +} + +export type DestinationType = string + +export interface DestinationTypeInfo { + disabledMessage: string + enabled: boolean + iconAltText: string + iconURL: string + isContactMethod: boolean + isEPTarget: boolean + isSchedOnCallNotify: boolean + name: string + requiredFields: DestinationFieldConfig[] + type: DestinationType + userDisclaimer: string +} + export interface EscalationPolicy { assignedTo: Target[] description: string @@ -372,6 +418,16 @@ export interface EscalationPolicyStep { targets: Target[] } +export interface FieldValueInput { + fieldID: string + value: string +} + +export interface FieldValuePair { + fieldID: string + value: string +} + export type Float = string export interface GQLAPIKey { @@ -626,6 +682,8 @@ export interface Query { configHints: ConfigHint[] debugMessageStatus: DebugMessageStatusInfo debugMessages: DebugMessage[] + destinationFieldValidate: boolean + destinationTypes: DestinationTypeInfo[] escalationPolicies: EscalationPolicyConnection escalationPolicy?: null | EscalationPolicy experimentalFlags: string[]