Get started with API Designer

I have tried to start with the API Designer and I could compile locally, start a local API server, ...

There is also an installed ApiServer on our IIS.

But I can't find out how to do any further fist step.

Is there any "getting started" document or video for API Designer?
Just provide me all the steps to get a single "Hello World" or something like that.

Patrick

I have Identity Manager 8.1.3

Parents
  • Hi Patrick,

    have you tried the APISamples on the DVD? I would start here with a normal Visual Studio.

    Regards,
    Geraldine

  • In the meantime I've got it working with postman.

    The only thing missing is the swagger-ui. best would be if I could have that on the API Server in my IIS.

  • We decided to skip swagger-ui (all html applications) for the moment due to other restrictions like  Requirements for non-destructive HTML5 app compilation , the compile time (you always have to compile both, the api-projects and the api-ui in order to get valid results in the swagger-ui), our proxy, and security considerations (e.g. npm loads binary packages from github).

  • I think I'll go on without swagger as well.

    My test with creating a new module works on the self hosted server.
    Now I have to find out, how can I make it work on the server.

    While login to /imx/login/...

    I get: [
    {
    "ErrorCode": "ApiServer0007",
    "Message": "For the parameter \"appId\", an invalid value was specified."
    }
    ]

  • I get ApiServer0007 if I use an unknown appId ("Technical name" in the API project).


  • I have called my PoC API Project "neu" as technical name.

    So for login I'm calling {{url}}/imx/login/neu. This works well within the self hosted server on my workstation.

    But it seems, that the API Server doesn't know the application at all.
    If I call any other url like {{url}}/neu/systemstatus I do not get any message about missing authentication, which I would expect.

    Isn't it enough to have the API Project in the DB and let it compile?
    Is there any other explizit deployment to the API Server?

  • That's part of your configuration, I think.
    E.g. "/systemstatus" is defined in QBM-Systemstatus and this file is assigned to the QBM_OperationsSupport project only. Thus, /opsupport/systemstatus is available, but in no other project here (and it requires authentication there - at least here with 8.1.4 it is defined so).

    So /neu/systemstatus should require authentication if not configured otherwise (and you don't have created a custom "systemstatus"-method with `AllowUnauthenticated()`). Which authentication modules do you use?

    What you can say is, if there is an endpoint /neu/systemstatus (and it's defined so), the API server knows the application.

    As I understand it, there's no obvious special explicit deployment for the API server, but an implicit one. The code has to be generated and stored in the App_Data/AssemblyCache-Folder. To be sure, you can delete (rename) that folder. If it's recreated, it seems to work.

    The "Standard"-update process refreshes the other files of the project (deploy target Server\Web\BusinessAPI) if configured in QBMWebApplication (I don't know the default behavior). This (I think) could be enforced with /admin/systeminfo/software/update

    These might help:

    • /admin/projects
      which appIds does the server know
    • /admin/config
      auth information of each project
    • /imx/sessions/neu
    • /imx/activemethods/neu
    • /imx/activeverbs/neu
    • QBM\dvd\AddOn\ApiSamples\Sdk05_Misc\06-ReinitApi.cs

  • To clarify

    ... The code has to be generated and stored in the App_Data/AssemblyCache-Folder ...

    I'm not really sure, though, but I think that code is loaded from the database, not recompiled on the API server.

  • Big shame on me, I've connected the API Server to the wrong DB. Confounded

    Connecting to the correct DB is much more successful.

    It works now!

Reply Children
No Data