You are not logged in.
Hi,
After updating mORMot2 to the latest version, Swagger is no longer working.
The URL format has changed.
Expected URL:
http://localhost:8282/root/Authentication/Login
Current URL:
http://localhost:8282/Authentication/Login
Offline
I don't understand which URL you are talking about.
How do you use or generate Swagger?
The URI did not change at TRestServer level.
Unless you did make some cusomization at HTTP router level on your side.
Offline
The REST server itself is working correctly. However, Swagger is generating the wrong URI. I didn't change even a single line of code after the upgrade.
This is the REST server code:
https://gist.github.com/a-nouri/d5347f8 … d1985736c5
swagger :
url -X 'POST' \
'http://192.168.1.12:8282/CustomerServic … stomerList' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-d '{}'
Last edited by anouri (2025-11-22 11:45:40)
Offline
I find why:
in prevoius version mORMotClient.json was:
{
"swagger": "2.0",
"info": {
"description": "Generated by PassakRestServer.exe (2025-10-28 18:42:15) using mORMot 2.3.10853 at 2025-10-29 11:46:42",
"title": "root API",
"version": ""
},
"host": "localhost:8282",
"basePath": "/root",
...
in new version :
"basePath": "/",
I don't know why this happen.
Offline
Somthing changed in mormot.soa.codegen.pas I think
I inslalled old version again.
Last edited by anouri (2025-11-22 13:39:42)
Offline