{"_id":"@cridev/nestjs-graphql-zod","_rev":"5-3c5fad81c9a308583505da73fde1d81d","name":"@cridev/nestjs-graphql-zod","dist-tags":{"latest":"3.4.5"},"versions":{"3.4.1":{"name":"@cridev/nestjs-graphql-zod","version":"3.4.1","keywords":["nestjs","zod","resolver","decorator","graphql","validation"],"author":{"name":"Tarık İnce","email":"incetarik@hotmail.com"},"license":"SEE LICENSE IN LICENSE","_id":"@cridev/nestjs-graphql-zod@3.4.1","maintainers":[{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"}],"homepage":"https://github.com/incetarik/nestjs-graphql-zod#readme","bugs":{"url":"https://github.com/incetarik/nestjs-graphql-zod/issues"},"dist":{"shasum":"aadb7b3de6257440121df20a2f8ca1e1cd5b65ef","tarball":"https://registry.npmjs.org/@cridev/nestjs-graphql-zod/-/nestjs-graphql-zod-3.4.1.tgz","fileCount":150,"integrity":"sha512-STE5694XCzSroZZjvamDe5grv3QZZXOM1n/G7yzMcfdyWQmu5+0uVkN9/cZm7m48eI6/B2kj8mzRg0ahMpr6zw==","signatures":[{"sig":"MEUCIQCHN03DbY9vOT2x15iWMA+9mz+miKJt48/J3rTvDc4KsgIgWu7e3voziOQpu38xD933oPmEVZSdUhFeuFt0UoBOEs4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":274652},"main":"dist/index.js","types":"dist/index.d.ts","gitHead":"5dc767ff1ca6b97967694f919e3c8cc269a26af5","scripts":{"test":"jest","build":"tsc","release":"release-it","prepublish":"tsc","build-watch":"tsc --watch"},"_npmUser":{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"},"repository":{"url":"git+https://github.com/incetarik/nestjs-graphql-zod.git","type":"git"},"_npmVersion":"10.9.2","description":"A library for integrating zod validation objects into nestjs graphql objects.","directories":{},"_nodeVersion":"23.10.0","_hasShrinkwrap":false,"devDependencies":{"zod":"3.24.3","rxjs":"7.8.2","graphql":"16.10.0","release-it":"*","typescript":"5.8.3","@nestjs/core":"11.0.11","@apollo/server":"4.11.3","@nestjs/common":"11.0.11","@nestjs/graphql":"13.0.3","reflect-metadata":"0.2.2","class-transformer":"0.5.1"},"peerDependencies":{"zod":"^3.24.0","rxjs":"^7.8.0","graphql":"^16.10.0","@nestjs/core":"^11.0.0","@nestjs/common":"^11.0.0","@nestjs/graphql":"^13.0.0","reflect-metadata":"^0.2.0","class-transformer":"^0.5.1"},"_npmOperationalInternal":{"tmp":"tmp/nestjs-graphql-zod_3.4.1_1746691076660_0.49126283682635075","host":"s3://npm-registry-packages-npm-production"}},"3.4.2":{"name":"@cridev/nestjs-graphql-zod","version":"3.4.2","keywords":["nestjs","zod","resolver","decorator","graphql","validation"],"author":{"name":"Tarık İnce","email":"incetarik@hotmail.com"},"license":"SEE LICENSE IN LICENSE","_id":"@cridev/nestjs-graphql-zod@3.4.2","maintainers":[{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"}],"homepage":"https://github.com/incetarik/nestjs-graphql-zod#readme","bugs":{"url":"https://github.com/incetarik/nestjs-graphql-zod/issues"},"dist":{"shasum":"87c58ccd95d44a793c5c0f586ebd2743c5aca89b","tarball":"https://registry.npmjs.org/@cridev/nestjs-graphql-zod/-/nestjs-graphql-zod-3.4.2.tgz","fileCount":150,"integrity":"sha512-joDe7ZiIb4SxLt4QyKywrVP6EXoT4vuA5cTSXukYsOEAfv7UE1tvbd7k8RevPw8O6f08Ap4LX0VIxEe3AAFdZA==","signatures":[{"sig":"MEQCICLg//zF+aSLu22eb0rHN3ebeX50EF8jkK1etrzGdLyNAiAvYYDhF5sxUhS5FteV9bI8cH3ToqfTyrXv2kR1rWq7Hw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":275572},"main":"dist/index.js","types":"dist/index.d.ts","gitHead":"5dc767ff1ca6b97967694f919e3c8cc269a26af5","scripts":{"test":"jest","build":"tsc","release":"release-it","prepublish":"tsc","build-watch":"tsc --watch"},"_npmUser":{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"},"repository":{"url":"git+https://github.com/incetarik/nestjs-graphql-zod.git","type":"git"},"_npmVersion":"10.9.2","description":"A library for integrating zod validation objects into nestjs graphql objects.","directories":{},"_nodeVersion":"23.10.0","_hasShrinkwrap":false,"devDependencies":{"zod":"3.24.3","rxjs":"7.8.2","graphql":"16.10.0","release-it":"*","typescript":"5.8.3","@nestjs/core":"11.0.11","@apollo/server":"4.11.3","@nestjs/common":"11.0.11","@nestjs/graphql":"13.0.3","reflect-metadata":"0.2.2","class-transformer":"0.5.1"},"peerDependencies":{"zod":"^3.24.0","rxjs":"^7.8.0","graphql":"^16.10.0","@nestjs/core":"^11.0.0","@nestjs/common":"^11.0.0","@nestjs/graphql":"^13.0.0","reflect-metadata":"^0.2.0","class-transformer":"^0.5.1"},"_npmOperationalInternal":{"tmp":"tmp/nestjs-graphql-zod_3.4.2_1746691671349_0.37762824030840214","host":"s3://npm-registry-packages-npm-production"}},"3.4.3":{"name":"@cridev/nestjs-graphql-zod","version":"3.4.3","keywords":["nestjs","zod","resolver","decorator","graphql","validation"],"author":{"name":"Tarık İnce","email":"incetarik@hotmail.com"},"license":"SEE LICENSE IN LICENSE","_id":"@cridev/nestjs-graphql-zod@3.4.3","maintainers":[{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"}],"homepage":"https://github.com/incetarik/nestjs-graphql-zod#readme","bugs":{"url":"https://github.com/incetarik/nestjs-graphql-zod/issues"},"dist":{"shasum":"11b32fb53bb38b3945f418f49c8dfbe54150039f","tarball":"https://registry.npmjs.org/@cridev/nestjs-graphql-zod/-/nestjs-graphql-zod-3.4.3.tgz","fileCount":154,"integrity":"sha512-GSOUZI953plsw/IxeCBODjLvtp6jAK/Ho/GhlhhDMKO/h7PRNgTW1sh5lnbmR3JjQUcNjF8vFlW+w1s0vFOpPQ==","signatures":[{"sig":"MEUCIF7+FN9+lpQVpFVYIA3mlPaxFBQKttptIon1hCI96ABUAiEA82noXMM9AwGjMw5j6JEUDR36gpiEFq8HT1ZROMLOQRI=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":277809},"main":"dist/index.js","types":"dist/index.d.ts","gitHead":"e07789602ba919a87fec762f396a16a5094e8a0d","scripts":{"test":"jest","build":"tsc","release":"release-it","prepublish":"tsc","build-watch":"tsc --watch"},"_npmUser":{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"},"repository":{"url":"git+https://github.com/incetarik/nestjs-graphql-zod.git","type":"git"},"_npmVersion":"10.9.2","description":"A library for integrating zod validation objects into nestjs graphql objects.","directories":{},"_nodeVersion":"23.10.0","_hasShrinkwrap":false,"devDependencies":{"zod":"3.24.3","rxjs":"7.8.2","graphql":"16.10.0","release-it":"*","typescript":"5.8.3","@nestjs/core":"11.0.11","@apollo/server":"4.11.3","@nestjs/common":"11.0.11","@nestjs/graphql":"13.0.3","reflect-metadata":"0.2.2","class-transformer":"0.5.1"},"peerDependencies":{"zod":"^3.24.0","rxjs":"^7.8.0","graphql":"^16.10.0","@nestjs/core":"^11.0.0","@nestjs/common":"^11.0.0","@nestjs/graphql":"^13.0.0","reflect-metadata":"^0.2.0","class-transformer":"^0.5.1"},"_npmOperationalInternal":{"tmp":"tmp/nestjs-graphql-zod_3.4.3_1746739764139_0.7020678199220733","host":"s3://npm-registry-packages-npm-production"}},"3.4.4":{"name":"@cridev/nestjs-graphql-zod","version":"3.4.4","keywords":["nestjs","zod","resolver","decorator","graphql","validation"],"author":{"name":"Tarık İnce","email":"incetarik@hotmail.com"},"license":"SEE LICENSE IN LICENSE","_id":"@cridev/nestjs-graphql-zod@3.4.4","maintainers":[{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"}],"homepage":"https://github.com/incetarik/nestjs-graphql-zod#readme","bugs":{"url":"https://github.com/incetarik/nestjs-graphql-zod/issues"},"dist":{"shasum":"37f8529657f08f685ccd34fe921a31438ffe6b07","tarball":"https://registry.npmjs.org/@cridev/nestjs-graphql-zod/-/nestjs-graphql-zod-3.4.4.tgz","fileCount":154,"integrity":"sha512-JXrsckqH3LIoWUS545U9rU0dOyICvfxBl4eretogz7aRVjDalwPEbRQDgIXhjaiYGcnS47GH41xK/JMsNvjOkg==","signatures":[{"sig":"MEYCIQDcZQuhAfTyKQUD3JvCGwlfrpmT7rAOk1lvfgv8xiNMUwIhAJIyD3vRqsfm8x0495wQn+IXyq1Ea5pOTQLdjKEA6luj","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":278276},"main":"dist/index.js","types":"dist/index.d.ts","gitHead":"e07789602ba919a87fec762f396a16a5094e8a0d","scripts":{"test":"jest","build":"tsc","release":"release-it","prepublish":"tsc","build-watch":"tsc --watch"},"_npmUser":{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"},"repository":{"url":"git+https://github.com/incetarik/nestjs-graphql-zod.git","type":"git"},"_npmVersion":"10.9.2","description":"A library for integrating zod validation objects into nestjs graphql objects.","directories":{},"_nodeVersion":"23.10.0","_hasShrinkwrap":false,"devDependencies":{"zod":"3.24.3","rxjs":"7.8.2","graphql":"16.10.0","release-it":"*","typescript":"5.8.3","@nestjs/core":"11.0.11","@apollo/server":"4.11.3","@nestjs/common":"11.0.11","@nestjs/graphql":"13.0.3","reflect-metadata":"0.2.2","class-transformer":"0.5.1"},"peerDependencies":{"zod":"^3.24.0","rxjs":"^7.8.0","graphql":"^16.10.0","@nestjs/core":"^11.0.0","@nestjs/common":"^11.0.0","@nestjs/graphql":"^13.0.0","reflect-metadata":"^0.2.0","class-transformer":"^0.5.1"},"_npmOperationalInternal":{"tmp":"tmp/nestjs-graphql-zod_3.4.4_1746740202358_0.47546280375213934","host":"s3://npm-registry-packages-npm-production"}},"3.4.5":{"name":"@cridev/nestjs-graphql-zod","version":"3.4.5","description":"A library for integrating zod validation objects into nestjs graphql objects.","main":"dist/index.js","types":"dist/index.d.ts","scripts":{"test":"jest","prepublish":"tsc","build":"tsc","build-watch":"tsc --watch","release":"release-it"},"repository":{"type":"git","url":"git+https://github.com/incetarik/nestjs-graphql-zod.git"},"keywords":[],"author":"","license":"SEE LICENSE IN LICENSE","peerDependencies":{"@nestjs/graphql":"^13.0.0","@nestjs/core":"^11.0.0","@nestjs/common":"^11.0.0","class-transformer":"^0.5.1","rxjs":"^7.8.0","reflect-metadata":"^0.2.0","graphql":"^16.10.0","zod":"^3.24.0"},"devDependencies":{"typescript":"5.8.3","release-it":"*","@nestjs/graphql":"13.0.3","@nestjs/core":"11.0.11","@nestjs/common":"11.0.11","@apollo/server":"4.11.3","class-transformer":"0.5.1","rxjs":"7.8.2","reflect-metadata":"0.2.2","graphql":"16.10.0","zod":"3.24.3"},"_id":"@cridev/nestjs-graphql-zod@3.4.5","gitHead":"e07789602ba919a87fec762f396a16a5094e8a0d","bugs":{"url":"https://github.com/incetarik/nestjs-graphql-zod/issues"},"homepage":"https://github.com/incetarik/nestjs-graphql-zod#readme","_nodeVersion":"23.10.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-PCyGkyJtYn8BFqkEr+0ukzXpm4DOtZqzQVNJocSIAFxomKZ6oC8ok8EBdOL0Oxz755vmMHcRd1YenHxoYGEIsQ==","shasum":"280158c7cd124b5dde5076d73c1ea1bcd592879e","tarball":"https://registry.npmjs.org/@cridev/nestjs-graphql-zod/-/nestjs-graphql-zod-3.4.5.tgz","fileCount":154,"unpackedSize":276792,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQDE02shurKE38Qhpz2BEiZIDqK2n4UI70IaL4729Yc4bAIgAmVI9i76QkOQXdKe21FOuJ/cZbRDHCEu8KgJD2t6YYI="}]},"_npmUser":{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"},"directories":{},"maintainers":[{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/nestjs-graphql-zod_3.4.5_1746741912837_0.7773703759413089"},"_hasShrinkwrap":false}},"time":{"created":"2025-05-08T07:57:56.570Z","modified":"2025-05-08T22:05:13.304Z","3.4.1":"2025-05-08T07:57:56.893Z","3.4.2":"2025-05-08T08:07:51.545Z","3.4.3":"2025-05-08T21:29:24.399Z","3.4.4":"2025-05-08T21:36:42.569Z","3.4.5":"2025-05-08T22:05:13.108Z"},"bugs":{"url":"https://github.com/incetarik/nestjs-graphql-zod/issues"},"license":"SEE LICENSE IN LICENSE","homepage":"https://github.com/incetarik/nestjs-graphql-zod#readme","keywords":[],"repository":{"type":"git","url":"git+https://github.com/incetarik/nestjs-graphql-zod.git"},"description":"A library for integrating zod validation objects into nestjs graphql objects.","maintainers":[{"name":"cridev","email":"cristiano.piscioneri.dev@gmail.com"}],"readme":"# nestjs-graphql-zod\n\n**Use `zod` validation objects in your GraphQL actions!**\n\nThis library provides utility functions and decorators similar to NestJS\nGraphQL decorators that lets you work with `zod` objects without the need of\nwriting GraphQL schema classes.\n\n- Nested `zod.object(...)` calls are supported. These will lead to generate\nanother GraphQL model for each definition.\n\n- Descriptions are supported. Additionally, for `zod.object(...)` definitions,\nto provide a custom name (instead of the dynamically generated ones) the\ndescription should be in `{ClassName}:{Description}` format\n(for example `UpdateModel: Contains properties that will be updated`). This\nwill cause a model generation with given class name with given description.\n\n- `zod.enum(...)` calls are supported. Enum models will be generated in GraphQL\nschema.\n\n- Primitive types are also supported and they will not cause any custom type\ncreation in GraphQL schema file.\n\n## Decorators\nAll the decorators are the same with underlying decorator with an exception that\nthe first parameter is the `zod` object.\n\nThe overloads of the underlying decorators are also reflected. Therefore it is\npossible to use an overload of the decorators provided by this library.\n\n### Method Decorators:\n- `@QueryWithZod`\n- `@MutationWithZod`\n- `@SubscriptionWithZod`\n\nThese decorators will do **output validation**.\nThey take `zod` object and validate the output with given `zod` object.\n\n### Parameter/Class Decorators\n- `@ZodArgs`\n- `@InputTypeWithZod`\n\nThese decorators will do **input validation**.\nThey take `zod` object and validate the input with given `zod` object.\n\n## Utility Functions\n- `modelFromZodBase`: Takes a `zod` input, options and a\ndecorator to decorate the dynamically built class with (such as `ObjectType`).\n\n- `modelFromZod`: Takes a `zod` input and options to build\nan `ObjectType` decorated class and return the class itself. The class will\ncontain the properties from the given `zod` input.\n\n- `inputFromZod`: Takes a `zod` input and options to build\nan `InputType` decorated class and return the class itself. The class will\ncontain the properties from the given `zod` input.\n\n- `getZodObject`: Takes an object and returns the source `zod` object that is\nused to build the class. For this function to return a defined value, the\nclasses should be built with `keepZodObject` option property set to `true`.\n\n- `setDefaultTypeProvider`: Takes a handler that will provide custom\n`GraphQLScalarType`s for any complex schemas. Therefore, it is also possible\nto set, for example, `JSONObject` for `z.record()` validations.\n\n- `getZodObjectName`: This function is producing a type string for the passed\nzod schema. The string will also be provided to the handler passed to\n`setDefaultTypeProvider` function.\n\n---\n\n## Setup\n- Add `nestjs-graphql-zod` to your dependencies in `package.json`.\n- Either use:\n  - Classes which you can create with `modelFromZod`.\n  - Use decorators for `GraphQL` action methods:\n    - `@MutationWithZod`\n    - `@QueryWithZod`\n    - `@SubscriptionWithZod`\n\n    or decorators for parameters:\n    - `@ZodArgs`\n\n    These are the same with their corresponding `GraphQL` method decorators.\n    Yet, they work with `zod` objects.\n\n## Example\n### Simple\n```ts\nimport * as zod from 'zod'\n\nconst UserZod = zod.object({\n  name: zod.string().describe('The name of the user'),\n  age: zod.number().int().gt(10).describe('The age of the user.'),\n  fields: zod.string().optional().array().optional().describe('The fields of the user'),\n  sortBy: zod.enum([ 'asc', 'desc' ]).describe('The sorting parameter of user.')\n}).describe('ExampleUser: Represents an example user instance.')\n\nclass UserResolver {\n  @QueryWithZod(UserZod)\n  async getUser() {\n    // You can simply return an object to be parsed and if the parsing is\n    // successful, then the data will be returned, otherwise an error will\n    // be thrown.\n\n    return {\n      name: 'User Name',\n      age: 15,\n      fields: [ 'Field 1', 'Field 2' ],\n      sortBy: 'asc'\n    }\n  }\n}\n```\n\nWith the example above, you will have the following generated `GraphQL` schema\ntype if you use `code-first` approach:\n\n```gql\n\"\"\" Represents an example user instance.\"\"\"\ntype ExampleUser {\n  \"\"\"The name of the user\"\"\"\n  name: String!\n\n  \"\"\"The age of the user.\"\"\"\n  age: Int!\n\n  \"\"\"The fields of the user\"\"\"\n  fields: [String]\n\n  \"\"\"The sorting parameter of user.\"\"\"\n  sortBy: ExampleUser_SortByEnum_0!\n}\n\n\"\"\"The sorting parameter of user.\"\"\"\nenum ExampleUser_SortByEnum_0 {\n  asc\n  desc\n}\n```\n\n### Nested Object\n```ts\nimport * as zod from 'zod'\n\nconst UserZod = zod.object({\n  name: zod.string().describe('The name of the user'),\n  age: zod.number().int().gt(10).describe('The age of the user.'),\n  fields: zod.string().optional().array().optional().describe('The fields of the user'),\n  sortBy: zod.enum([ 'asc', 'desc' ]).describe('The sorting parameter of user.'),\n  settings: zod.object({\n    darkTheme: zod.boolean().optional().describe('The dark theme setting'),\n    ratio: zod.number().describe('This will be float by default'),\n    profile: zod.object({\n      showImage: zod.boolean().describe('Indicates whether the user is showing images.'),\n    }).describe('UserProfileSetting: Represents user profile settings.'),\n  }).describe('ExampleUserSettings: The user settings.'),\n}).describe('ExampleUser: Represents an example user instance.')\n\nclass UserResolver {\n  @QueryWithZod(UserZod)\n  async getUser() {\n    // You can simply return an object to be parsed and if the parsing is\n    // successful, then the data will be returned, otherwise an error will\n    // be thrown.\n\n    return {\n      name: 'User Name',\n      age: 15,\n      fields: [ 'Field 1', 'Field 2' ],\n      sortBy: 'asc',\n      settings: {\n        darkTheme: false,\n        ratio: 2.5,\n        profile: {\n          showImage: true\n        }\n      }\n    }\n  }\n}\n```\n\nWith the example above, you will have the following generated `GraphQL` schema\ntype if you use `code-first` approach:\n\n```gql\n\"\"\" Represents an example user instance.\"\"\"\ntype ExampleUser {\n  \"\"\"The name of the user\"\"\"\n  name: String!\n\n  \"\"\"The age of the user.\"\"\"\n  age: Int!\n\n  \"\"\"The fields of the user\"\"\"\n  fields: [String]\n\n  \"\"\"The sorting parameter of user.\"\"\"\n  sortBy: ExampleUser_SortByEnum_0!\n\n  \"\"\"ExampleUserSettings: The user settings.\"\"\"\n  settings: ExampleUser_Settings!\n}\n\n\"\"\"The sorting parameter of user.\"\"\"\nenum ExampleUser_SortByEnum_0 {\n  asc\n  desc\n}\n\n\"\"\"ExampleUserSettings: The user settings.\"\"\"\ntype ExampleUser_Settings {\n  \"\"\"The dark theme setting\"\"\"\n  darkTheme: Boolean\n\n  \"\"\"This will be float by default\"\"\"\n  ratio: Float!\n\n  \"\"\"UserProfileSetting: Represents user profile settings.\"\"\"\n  profile: ExampleUser_Settings_Profile!\n}\n\n\"\"\"UserProfileSetting: Represents user profile settings.\"\"\"\ntype ExampleUser_Settings_Profile {\n  \"\"\"Indicates whether the user is showing images.\"\"\"\n  showImage: Boolean!\n}\n```\n\n### InputType/Args Example\n```ts\nimport * as zod from 'zod'\nimport { ZodArgs } from 'nestjs-graphql-zod'\n\nconst RequestSchema = zod.object({\n  username: zod.string().min(5).max(20).describe('The username of the request owner'),\n  email: zod.string().email().describe('The email of the user'),\n  changes: zod.object({\n    themeSelection: zod.enum([ 'light', 'dark' ]).describe('The theme type'),\n    permissions: zod.object({\n      add: zod.number().array().describe('The flags added to the user permissions'),\n      remove: zod.number().array().describe('The flags removed to the user permissions'),\n      isAdmin: zod.boolean().describe('Indicates if the user is an admin')\n    }).describe('The permissions change set of the user')\n  }).describe('The changes made by the user')\n}).describe('RequestSchema: The request schema type for changing user data')\n\nclass ExampleResolver() {\n  @Query(() => Boolean)\n  processRequest(@ZodArgs(RequestSchema) input: ZodArgs.Of<typeof RequestSchema>) {\n    // The input will contain all the properties validated according to the\n    // schema defined above. If the validation was failed, the user will get\n    // BadRequest error and this method will not be called.\n\n    // The @ZodArgs(Schema) decorator is behaving like\n    // @Args() + @InputType() decorators.\n    //\n    // The @InputType() is applied to underlying class, the @Args() is applied\n    // to take the input as the parameter. By default, the name of the\n    // property will be 'input'. This can be changed through the overloads\n    // of the decorator.\n  }\n}\n```\n\nWith the example above, you will have the following generated `GraphQL` schema\ntype if you use `code-first` approach:\n\n```gql\n\"\"\"The request schema type for changing user data\"\"\"\ninput RequestSchema {\n  \"\"\"The username of the request owner\"\"\"\n  username: String!\n\n  \"\"\"The email of the user\"\"\"\n  email: String!\n\n  \"\"\"The changes made by the user\"\"\"\n  changes: RequestSchema_Changes!\n}\n\n\"\"\"The request schema type for changing user data\"\"\"\ninput RequestSchema_Changes {\n  \"\"\"The theme type\"\"\"\n  themeSelection: RequestSchema_Changes_ThemeSelectionEnum_0!\n\n  \"\"\"The permissions change set of the user\"\"\"\n  permissions: RequestSchema_Changes_Permissions!\n}\n\n\"\"\"The theme type\"\"\"\nenum RequestSchema_Changes_ThemeSelectionEnum_0 {\n  light\n  dark\n}\n\n\"\"\"The request schema type for changing user data\"\"\"\ninput RequestSchema_Changes_Permissions {\n  \"\"\"The flags added to the user permissions\"\"\"\n  add: [Float!]!\n\n  \"\"\"The flags removed to the user permissions\"\"\"\n  remove: [Float!]!\n\n  \"\"\"Indicates if the user is an admin\"\"\"\n  isAdmin: Boolean!\n}\n```\n\nInline `@ZodArgs` example with complex type input.\n```ts\n\nsetDefaultTypeProvider((typeName) => {\n  if (typeName.startsWith('Record')) {\n    return GraphQLJSONObject // a custom scalar type\n  }\n\n  // Otherwise, return no custom scalar type which will cause\n  // a parsing error.\n})\n\nclass ExampleResolver() {\n  @Query(() => Boolean)\n  inlineExample(\n    @ZodArgs(zod.number().gt(10).array()) numberArray: number[],\n    @ZodArgs(zod.record(zod.number())) dictionary: Record<string, number>,\n    @ZodArgs(zod.string().url().optional()) urlString?: string,\n  ) {\n    // Here the @ZodArgs(Schema) decorator is inlined and will produce\n    // corresponding schema file. If the types are primitives, there will\n    // be no custom proxy type creation.\n\n    // The record example above will require a custom scalar type to be\n    // provided. The provider function can be set in the decorator properties\n    // or through the global/default setter function as in this example.\n  }\n}\n```\n\n# Support\nTo support the project, you can send donations to following addresses:\n\n```md\n- Bitcoin     : bc1qtut2ss8udkr68p6k6axd0na6nhvngm5dqlyhtn\n- Bitcoin Cash: qzmmv43ztae0tfsjx8zf4wwnq3uk6k7zzgcfr9jruk\n- Ether       : 0xf542BED91d0218D9c195286e660da2275EF8eC84\n```\n","readmeFilename":"README.md"}