Skip to content

Swagger files with POST instead of GET #1146

Answered by stijnvanhulle
filipjakov asked this question in Q&A
Discussion options

You must be logged in to vote

For that you can use methods, see https://www.kubb.dev/plugins/swagger-tanstack-query/#methods

override: [
	// {
	// 	type: 'operationId',
	// 	pattern: '.*_get.*',
	// 	options: {
	// 		mutate: false,
	// 	},
	// },
	{
		type: 'operationId',
		pattern: '.*_get.*',
		options: {
			mutate: {
                            variablesType: 'hook',
                             methods: ['get',  'post', 'put', 'delete' ],
                         },
		},
	},
],

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by filipjakov
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants