{"agent":"codex","input":"Upgrade Payload in this repository to the newest release tagged latest on the current major, and open a pull request. Read package.json, pnpm-workspace.yaml, the package.json files under preview-runtimes, mise.toml, tsconfig.json, .env.example, src/payload.config.ts, src/migrations and the workflows under .github first. List every dependency whose name is payload or starts with @payloadcms/, its current version, and whether it belongs to the core set that shares one version. Install pnpm at the version in packageManager and the Node major in mise.toml. Baseline on the untouched branch: pnpm install, pnpm lint, pnpm exec tsc, keeping the output, and copy src/payload-types.ts and the admin import map aside. From the registry read the target version, its engines.node and the peerDependencies of @payloadcms/next at that version; compare them with the Node version this repository pins and the installed next version, and report any conflict before going on. Set payload and every core @payloadcms package in the root package.json to the target, exactly, with no range. Do not change the packages under preview-runtimes, @payloadcms/eslint-config, @payloadcms/eslint-plugin, next or react. Run pnpm install, then pnpm generate:types and pnpm generate:importmap, and diff both generated files against the copies. Read the release notes between the two versions and tie each generated-file difference and each new lint or type error to a note. Fix errors in this repository's code that the upgrade causes; list any you cannot. Do not run pnpm build and do not start a database unless this prompt is extended to ask for it. If the repository is already on the target, end with one line saying so and open nothing. In the pull request give the versions before and after, the Node and Next.js requirements you read, the lint and type-check results on both sides, the generated-file diffs, and a short list of what to check on a preview deployment.","resources":[{"url":"https://github.com/your-org/your-app"}]}