0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-20 22:42:53 -05:00

🐛 Fixed /canary/ API endpoints 404s

refs https://github.com/TryGhost/Toolbox/issues/169
refs 7becf0a2b2

- The referenced commit has dropped existance of Content and Admin APIs under `/canary/` prefix, which made a breaking change and clients that are still relying on "canary" started to break.
- The `/canary/` prefix should be used up untill the introduction of Ghost v5, otherwise we run the risk of accidentally breaking API clients.
This commit is contained in:
Naz 2022-03-21 19:11:05 +08:00
parent 30f73b73fe
commit 25e5cb46de
2 changed files with 5 additions and 2 deletions

View file

@ -22,6 +22,9 @@ module.exports = function setupApiApp() {
apiApp.lazyUse(urlUtils.getVersionPath({version: 'v4', type: 'content'}), require('./canary/content/app'));
apiApp.lazyUse(urlUtils.getVersionPath({version: 'v4', type: 'admin'}), require('./canary/admin/app'));
apiApp.lazyUse(urlUtils.getVersionPath({version: 'v5', type: 'content'}), require('./canary/content/app'));
apiApp.lazyUse(urlUtils.getVersionPath({version: 'v5', type: 'admin'}), require('./canary/admin/app'));
apiApp.lazyUse(urlUtils.getVersionPath({version: 'canary', type: 'content'}), require('./canary/content/app'));
apiApp.lazyUse(urlUtils.getVersionPath({version: 'canary', type: 'admin'}), require('./canary/admin/app'));

View file

@ -82,8 +82,8 @@
"all": ["v2", "v3", "v4", "v5", "canary"],
"default": "v4",
"canary": {
"admin": "admin",
"content": "content"
"admin": "canary/admin",
"content": "canary/content"
},
"v5": {
"admin": "admin",