{"version":3,"file":"apply.cjs","names":[],"sources":["../../../../src/rest/commands/schema/apply.ts"],"sourcesContent":["import type { RestCommand } from '../../types.js';\nimport type { SchemaDiffOutput } from './diff.js';\n\n/**\n * Update the instance's schema by passing the diff previously retrieved via /schema/diff endpoint in the request body. This endpoint is only available to admin users.\n * @param diff JSON object containing hash and diffs of collections, fields, and relations to apply.\n * @returns Empty body.\n */\nexport const schemaApply =\n\t<Schema>(diff: SchemaDiffOutput): RestCommand<void, Schema> =>\n\t() => ({\n\t\tmethod: 'POST',\n\t\tpath: '/schema/apply',\n\t\tbody: JSON.stringify(diff),\n\t});\n"],"mappings":"AAQA,MAAa,EACH,QACF,CACN,OAAQ,OACR,KAAM,gBACN,KAAM,KAAK,UAAU,EAAK,CAC1B"}