// Code generated by api_gen. DO NOT EDIT. package client import ( "context" "encoding/json" "fmt" "atlas9.dev/c/demo/api" ) // CommandNames lists every endpoint the CLI can invoke, in registration order. var CommandNames = []string{ "Account_PruneTokens", "Account_Register", "Account_RequestPasswordReset", "Account_ResendVerification", "Account_ResetPassword", "Account_SendEmailVerification", "Account_SendPasswordReset", "Account_Verify", "Audit_List", "Audit_ListByUser", "BotGrants_Add", "BotGrants_ListByTenant", "BotGrants_Remove", "BotKeys_Create", "BotKeys_Get", "BotKeys_List", "BotKeys_SetExpiration", "Bots_Create", "Bots_Delete", "Bots_Get", "Bots_List", "Bots_Update", "Domain_Create", "Domain_Delete", "Domain_Get", "Domain_List", "Domain_Verify", "Entitlements_Read", "GroupGrants_Add", "GroupGrants_ListByTenant", "GroupGrants_Remove", "Groups_AddMember", "Groups_Create", "Groups_Delete", "Groups_Get", "Groups_List", "Groups_ListByTenant", "Groups_ListMemberGroups", "Groups_ListMembers", "Groups_RemoveMember", "Groups_Update", "Health", "Identity_Login", "Identity_Logout", "Identity_PruneSessions", "Identity_VerifyMFA", "Mfa_ConfirmEnrollment", "Mfa_Disable", "Mfa_GetPolicy", "Mfa_GetStatus", "Mfa_SetPolicy", "Mfa_StartEnrollment", "Profiles_Get", "Profiles_Update", "Roles_Create", "Roles_Delete", "Roles_Get", "Roles_List", "Roles_ListByTenant", "Roles_Update", "Slack_CreateEndpoint", "Slack_DeleteEndpoint", "Slack_Deliver", "Slack_GetEndpoint", "Slack_ListEndpoints", "Slack_UpdateEndpoint", "Sso_Check", "Sso_GetCallback", "Sso_Login", "Sso_PostCallback", "TenantInvitations_Accept", "TenantInvitations_Create", "TenantInvitations_Decline", "TenantInvitations_Delete", "TenantInvitations_List", "TenantInvitations_ListByEmail", "TenantInvitations_SendInvitation", "TenantMembers_Add", "TenantMembers_Get", "TenantMembers_ListByTenant", "TenantMembers_ListByUser", "TenantMembers_Remove", "Tenants_Create", "Tenants_Delete", "Tenants_Get", "Tenants_List", "Tenants_Update", "Todos_AddToList", "Todos_CreateItem", "Todos_CreateList", "Todos_DeleteItem", "Todos_DeleteList", "Todos_GetItem", "Todos_GetList", "Todos_ListEntriesByItems", "Todos_ListItems", "Todos_ListLists", "Todos_RemoveFromList", "Todos_UpdateItem", "Todos_UpdateList", "UserGrants_Add", "UserGrants_ListByTenant", "UserGrants_ListByUser", "UserGrants_Remove", "Users_GetByEmail", "Users_List", "Users_ListByTenant", "Webhooks_CreateEndpoint", "Webhooks_DeleteEndpoint", "Webhooks_Deliver", "Webhooks_GetEndpoint", "Webhooks_ListEndpoints", "Webhooks_UpdateEndpoint", } // Invoke decodes body into the request type for the named command, calls the // corresponding client method, and returns the typed response. An unknown name // returns an error. func Invoke(ctx context.Context, c *Client, name string, body []byte) (any, error) { switch name { case "Account_PruneTokens": var req api.Account_PruneTokensReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Account_PruneTokens(ctx, &req) case "Account_Register": var req api.Account_RegisterReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Account_Register(ctx, &req) case "Account_RequestPasswordReset": var req api.Account_RequestPasswordResetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Account_RequestPasswordReset(ctx, &req) case "Account_ResendVerification": var req api.Account_ResendVerificationReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Account_ResendVerification(ctx, &req) case "Account_ResetPassword": var req api.Account_ResetPasswordReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Account_ResetPassword(ctx, &req) case "Account_SendEmailVerification": var req api.Account_SendEmailVerificationReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Account_SendEmailVerification(ctx, &req) case "Account_SendPasswordReset": var req api.Account_SendPasswordResetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Account_SendPasswordReset(ctx, &req) case "Account_Verify": var req api.Account_VerifyReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Account_Verify(ctx, &req) case "Audit_List": var req api.Audit_ListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Audit_List(ctx, &req) case "Audit_ListByUser": var req api.Audit_ListByUserReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Audit_ListByUser(ctx, &req) case "BotGrants_Add": var req api.BotGrants_AddReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.BotGrants_Add(ctx, &req) case "BotGrants_ListByTenant": var req api.BotGrants_ListByTenantReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.BotGrants_ListByTenant(ctx, &req) case "BotGrants_Remove": var req api.BotGrants_RemoveReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.BotGrants_Remove(ctx, &req) case "BotKeys_Create": var req api.BotKeys_CreateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.BotKeys_Create(ctx, &req) case "BotKeys_Get": var req api.BotKeys_GetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.BotKeys_Get(ctx, &req) case "BotKeys_List": var req api.BotKeys_ListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.BotKeys_List(ctx, &req) case "BotKeys_SetExpiration": var req api.BotKeys_SetExpirationReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.BotKeys_SetExpiration(ctx, &req) case "Bots_Create": var req api.Bots_CreateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Bots_Create(ctx, &req) case "Bots_Delete": var req api.Bots_DeleteReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Bots_Delete(ctx, &req) case "Bots_Get": var req api.Bots_GetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Bots_Get(ctx, &req) case "Bots_List": var req api.Bots_ListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Bots_List(ctx, &req) case "Bots_Update": var req api.Bots_UpdateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Bots_Update(ctx, &req) case "Domain_Create": var req api.Domain_CreateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Domain_Create(ctx, &req) case "Domain_Delete": var req api.Domain_DeleteReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Domain_Delete(ctx, &req) case "Domain_Get": var req api.Domain_GetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Domain_Get(ctx, &req) case "Domain_List": var req api.Domain_ListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Domain_List(ctx, &req) case "Domain_Verify": var req api.Domain_VerifyReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Domain_Verify(ctx, &req) case "Entitlements_Read": var req api.Entitlements_ReadReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Entitlements_Read(ctx, &req) case "GroupGrants_Add": var req api.GroupGrants_AddReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.GroupGrants_Add(ctx, &req) case "GroupGrants_ListByTenant": var req api.GroupGrants_ListByTenantReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.GroupGrants_ListByTenant(ctx, &req) case "GroupGrants_Remove": var req api.GroupGrants_RemoveReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.GroupGrants_Remove(ctx, &req) case "Groups_AddMember": var req api.Groups_AddMemberReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_AddMember(ctx, &req) case "Groups_Create": var req api.Groups_CreateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_Create(ctx, &req) case "Groups_Delete": var req api.Groups_DeleteReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_Delete(ctx, &req) case "Groups_Get": var req api.Groups_GetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_Get(ctx, &req) case "Groups_List": var req api.Groups_ListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_List(ctx, &req) case "Groups_ListByTenant": var req api.Groups_ListByTenantReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_ListByTenant(ctx, &req) case "Groups_ListMemberGroups": var req api.Groups_ListMemberGroupsReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_ListMemberGroups(ctx, &req) case "Groups_ListMembers": var req api.Groups_ListMembersReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_ListMembers(ctx, &req) case "Groups_RemoveMember": var req api.Groups_RemoveMemberReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_RemoveMember(ctx, &req) case "Groups_Update": var req api.Groups_UpdateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Groups_Update(ctx, &req) case "Health": var req api.HealthReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Health(ctx, &req) case "Identity_Login": var req api.Identity_LoginReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Identity_Login(ctx, &req) case "Identity_Logout": var req api.Identity_LogoutReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Identity_Logout(ctx, &req) case "Identity_PruneSessions": var req api.Identity_PruneSessionsReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Identity_PruneSessions(ctx, &req) case "Identity_VerifyMFA": var req api.Identity_VerifyMFAReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Identity_VerifyMFA(ctx, &req) case "Mfa_ConfirmEnrollment": var req api.Mfa_ConfirmEnrollmentReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Mfa_ConfirmEnrollment(ctx, &req) case "Mfa_Disable": var req api.Mfa_DisableReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Mfa_Disable(ctx, &req) case "Mfa_GetPolicy": var req api.Mfa_GetPolicyReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Mfa_GetPolicy(ctx, &req) case "Mfa_GetStatus": var req api.Mfa_GetStatusReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Mfa_GetStatus(ctx, &req) case "Mfa_SetPolicy": var req api.Mfa_SetPolicyReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Mfa_SetPolicy(ctx, &req) case "Mfa_StartEnrollment": var req api.Mfa_StartEnrollmentReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Mfa_StartEnrollment(ctx, &req) case "Profiles_Get": var req api.Profiles_GetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Profiles_Get(ctx, &req) case "Profiles_Update": var req api.Profiles_UpdateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Profiles_Update(ctx, &req) case "Roles_Create": var req api.Roles_CreateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Roles_Create(ctx, &req) case "Roles_Delete": var req api.Roles_DeleteReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Roles_Delete(ctx, &req) case "Roles_Get": var req api.Roles_GetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Roles_Get(ctx, &req) case "Roles_List": var req api.Roles_ListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Roles_List(ctx, &req) case "Roles_ListByTenant": var req api.Roles_ListByTenantReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Roles_ListByTenant(ctx, &req) case "Roles_Update": var req api.Roles_UpdateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Roles_Update(ctx, &req) case "Slack_CreateEndpoint": var req api.Slack_CreateEndpointReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Slack_CreateEndpoint(ctx, &req) case "Slack_DeleteEndpoint": var req api.Slack_DeleteEndpointReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Slack_DeleteEndpoint(ctx, &req) case "Slack_Deliver": var req api.Slack_DeliverReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Slack_Deliver(ctx, &req) case "Slack_GetEndpoint": var req api.Slack_GetEndpointReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Slack_GetEndpoint(ctx, &req) case "Slack_ListEndpoints": var req api.Slack_ListEndpointsReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Slack_ListEndpoints(ctx, &req) case "Slack_UpdateEndpoint": var req api.Slack_UpdateEndpointReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Slack_UpdateEndpoint(ctx, &req) case "Sso_Check": var req api.Sso_CheckReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Sso_Check(ctx, &req) case "Sso_GetCallback": var req api.Sso_GetCallbackReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Sso_GetCallback(ctx, &req) case "Sso_Login": var req api.Sso_LoginReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Sso_Login(ctx, &req) case "Sso_PostCallback": var req api.Sso_PostCallbackReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Sso_PostCallback(ctx, &req) case "TenantInvitations_Accept": var req api.TenantInvitations_AcceptReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantInvitations_Accept(ctx, &req) case "TenantInvitations_Create": var req api.TenantInvitations_CreateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantInvitations_Create(ctx, &req) case "TenantInvitations_Decline": var req api.TenantInvitations_DeclineReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantInvitations_Decline(ctx, &req) case "TenantInvitations_Delete": var req api.TenantInvitations_DeleteReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantInvitations_Delete(ctx, &req) case "TenantInvitations_List": var req api.TenantInvitations_ListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantInvitations_List(ctx, &req) case "TenantInvitations_ListByEmail": var req api.TenantInvitations_ListByEmailReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantInvitations_ListByEmail(ctx, &req) case "TenantInvitations_SendInvitation": var req api.TenantInvitations_SendInvitationReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantInvitations_SendInvitation(ctx, &req) case "TenantMembers_Add": var req api.TenantMembers_AddReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantMembers_Add(ctx, &req) case "TenantMembers_Get": var req api.TenantMembers_GetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantMembers_Get(ctx, &req) case "TenantMembers_ListByTenant": var req api.TenantMembers_ListByTenantReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantMembers_ListByTenant(ctx, &req) case "TenantMembers_ListByUser": var req api.TenantMembers_ListByUserReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantMembers_ListByUser(ctx, &req) case "TenantMembers_Remove": var req api.TenantMembers_RemoveReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.TenantMembers_Remove(ctx, &req) case "Tenants_Create": var req api.Tenants_CreateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Tenants_Create(ctx, &req) case "Tenants_Delete": var req api.Tenants_DeleteReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Tenants_Delete(ctx, &req) case "Tenants_Get": var req api.Tenants_GetReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Tenants_Get(ctx, &req) case "Tenants_List": var req api.Tenants_ListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Tenants_List(ctx, &req) case "Tenants_Update": var req api.Tenants_UpdateReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Tenants_Update(ctx, &req) case "Todos_AddToList": var req api.Todos_AddToListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_AddToList(ctx, &req) case "Todos_CreateItem": var req api.Todos_CreateItemReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_CreateItem(ctx, &req) case "Todos_CreateList": var req api.Todos_CreateListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_CreateList(ctx, &req) case "Todos_DeleteItem": var req api.Todos_DeleteItemReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_DeleteItem(ctx, &req) case "Todos_DeleteList": var req api.Todos_DeleteListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_DeleteList(ctx, &req) case "Todos_GetItem": var req api.Todos_GetItemReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_GetItem(ctx, &req) case "Todos_GetList": var req api.Todos_GetListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_GetList(ctx, &req) case "Todos_ListEntriesByItems": var req api.Todos_ListEntriesByItemsReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_ListEntriesByItems(ctx, &req) case "Todos_ListItems": var req api.Todos_ListItemsReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_ListItems(ctx, &req) case "Todos_ListLists": var req api.Todos_ListListsReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_ListLists(ctx, &req) case "Todos_RemoveFromList": var req api.Todos_RemoveFromListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_RemoveFromList(ctx, &req) case "Todos_UpdateItem": var req api.Todos_UpdateItemReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_UpdateItem(ctx, &req) case "Todos_UpdateList": var req api.Todos_UpdateListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Todos_UpdateList(ctx, &req) case "UserGrants_Add": var req api.UserGrants_AddReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.UserGrants_Add(ctx, &req) case "UserGrants_ListByTenant": var req api.UserGrants_ListByTenantReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.UserGrants_ListByTenant(ctx, &req) case "UserGrants_ListByUser": var req api.UserGrants_ListByUserReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.UserGrants_ListByUser(ctx, &req) case "UserGrants_Remove": var req api.UserGrants_RemoveReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.UserGrants_Remove(ctx, &req) case "Users_GetByEmail": var req api.Users_GetByEmailReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Users_GetByEmail(ctx, &req) case "Users_List": var req api.Users_ListReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Users_List(ctx, &req) case "Users_ListByTenant": var req api.Users_ListByTenantReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Users_ListByTenant(ctx, &req) case "Webhooks_CreateEndpoint": var req api.Webhooks_CreateEndpointReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Webhooks_CreateEndpoint(ctx, &req) case "Webhooks_DeleteEndpoint": var req api.Webhooks_DeleteEndpointReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Webhooks_DeleteEndpoint(ctx, &req) case "Webhooks_Deliver": var req api.Webhooks_DeliverReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Webhooks_Deliver(ctx, &req) case "Webhooks_GetEndpoint": var req api.Webhooks_GetEndpointReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Webhooks_GetEndpoint(ctx, &req) case "Webhooks_ListEndpoints": var req api.Webhooks_ListEndpointsReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Webhooks_ListEndpoints(ctx, &req) case "Webhooks_UpdateEndpoint": var req api.Webhooks_UpdateEndpointReq if len(body) > 0 { if err := json.Unmarshal(body, &req); err != nil { return nil, fmt.Errorf("decoding request: %w", err) } } return c.Webhooks_UpdateEndpoint(ctx, &req) default: return nil, fmt.Errorf("unknown command: %s", name) } }