/** * GraphQL Resolvers */ import { GraphQLScalarType } from 'graphql'; import { PubSub } from 'graphql-subscriptions'; import { GraphQLContext } from './server'; declare const pubsub: PubSub>; type Model = Record & { id: string; }; type Policy = Record & { id: string; }; type User = Record & { id: string; }; type Request = Record & { id: string; }; type Webhook = Record & { id: string; }; interface IdArg { id: string; } interface PaginationArgs { limit?: number; offset?: number; } interface DateRangeArgs { dateRange?: { start: string; end: string; }; } interface CreateArgs { input: Record; } interface UpdateArgs { id: string; input: Record; } interface GenerateApiKeyArgs { userId: string; name: string; } interface RevokeApiKeyArgs { keyId: string; } interface AlertSeverityArgs { severity?: string; } export declare const DateTimeResolver: GraphQLScalarType; export declare const JSONResolver: GraphQLScalarType; export declare const resolvers: { DateTime: GraphQLScalarType; JSON: GraphQLScalarType; Query: { models: (_: unknown, __: unknown, context: GraphQLContext) => Promise; model: (_: unknown, { id }: IdArg, context: GraphQLContext) => Promise; policies: (_: unknown, __: unknown, context: GraphQLContext) => Promise; policy: (_: unknown, { id }: IdArg, context: GraphQLContext) => Promise; users: (_: unknown, __: unknown, context: GraphQLContext) => Promise; user: (_: unknown, { id }: IdArg, context: GraphQLContext) => Promise; me: (_: unknown, __: unknown, context: GraphQLContext) => Promise; requests: (_: unknown, args: PaginationArgs, context: GraphQLContext) => Promise; request: (_: unknown, { id }: IdArg, context: GraphQLContext) => Promise; metrics: (_: unknown, args: DateRangeArgs, context: GraphQLContext) => Promise; analytics: (_: unknown, args: DateRangeArgs, context: GraphQLContext) => Promise; webhooks: (_: unknown, __: unknown, context: GraphQLContext) => Promise; webhook: (_: unknown, { id }: IdArg, context: GraphQLContext) => Promise; }; Mutation: { createModel: (_: unknown, { input }: CreateArgs, context: GraphQLContext) => Promise; updateModel: (_: unknown, { id, input }: UpdateArgs, context: GraphQLContext) => Promise; deleteModel: (_: unknown, { id }: IdArg, context: GraphQLContext) => Promise; createPolicy: (_: unknown, { input }: CreateArgs, context: GraphQLContext) => Promise; updatePolicy: (_: unknown, { id, input }: UpdateArgs, context: GraphQLContext) => Promise; deletePolicy: (_: unknown, { id }: IdArg, context: GraphQLContext) => Promise; createUser: (_: unknown, { input }: CreateArgs, context: GraphQLContext) => Promise; updateUser: (_: unknown, { id, input }: UpdateArgs, context: GraphQLContext) => Promise; deleteUser: (_: unknown, { id }: IdArg, context: GraphQLContext) => Promise; generateApiKey: (_: unknown, { userId, name }: GenerateApiKeyArgs, context: GraphQLContext) => Promise; revokeApiKey: (_: unknown, { keyId }: RevokeApiKeyArgs, context: GraphQLContext) => Promise; createWebhook: (_: unknown, { input }: CreateArgs, context: GraphQLContext) => Promise; updateWebhook: (_: unknown, { id, input }: UpdateArgs, context: GraphQLContext) => Promise; deleteWebhook: (_: unknown, { id }: IdArg, context: GraphQLContext) => Promise; }; Subscription: { requestCreated: { subscribe: () => AsyncIterableIterator; }; requestCompleted: { subscribe: () => AsyncIterableIterator; }; requestFailed: { subscribe: () => AsyncIterableIterator; }; modelAdded: { subscribe: () => AsyncIterableIterator; }; modelUpdated: { subscribe: () => AsyncIterableIterator; }; modelRemoved: { subscribe: () => AsyncIterableIterator; }; metricsUpdated: { subscribe: () => AsyncIterableIterator; }; alertTriggered: { subscribe: (_: unknown, { severity }: AlertSeverityArgs) => AsyncIterableIterator; }; }; User: { apiKeys: (parent: User, _: unknown, context: GraphQLContext) => Promise; }; Webhook: { deliveries: (parent: Webhook, _: unknown, context: GraphQLContext) => Promise; }; }; export { pubsub }; //# sourceMappingURL=resolvers.d.ts.map