Either the solution Gilles gave, or use a reverse proxy (like nginx) to globally build routes for your web API.
Uniface cannot deal with that, and tomcat is rather limited (rewrite.config is tidy).
With a "facade" proxy server, you don't have to worry about the sexiness of the API, or even to make it HTTPS (anything behind the proxy can be insecure and roles are properly defined between the public service and the content provider service).
Richard
------------------------------
Richard Gill
Software Developer
Dedalus Healthcare France
Artigues Pres Bordeaux FR
------------------------------
Original Message:
Sent: 12-19-2023 07:56
From: Hortion Gilles
Subject: REST API and NAME convention
Hello Yves,
With uniface i think the only think you can do , it's create an usp component named 'isalive' and get request in the exec trigger, and then, redirect to your 'SFY00000S' component.
With Tomcat you can develop an java servlet named 'isalive' and redirect the request toward your uniface url.
Also with Tomcat If you use the "org.apache.catalina.valves.rewrite.RewriteValve" you can maybe use an rewrite.config file (same folder as the web.inf)
Gilles.
------------------------------
Hortion Gilles
Dedalus Healthcare France
Artigues Pres Bordeaux FR
Original Message:
Sent: 12-18-2023 10:22
From: Yves De Montmollin
Subject: REST API and NAME convention
Hello,
We are creating REST interface for web access.
Is it possible to use a name for the REST and an other name for the svc
We have naming standards but the are not end-user friendly
for exemple, the url would be https://.../isAlive
but the internal svc woud be SFY00000S
I just wonder if there could be a http service renamer or something like that...
I tried to create a signature or to use the [SERVICES_EXEC] of the .asn but I could not achieve what I tried.
If anyone have an idea
Thanks in advance
Yves
------------------------------
Yves De Montmollin
Aon Suisse Sa
------------------------------