Using REST API with SWAGGER-UI


#1

Hello everyone,

I try to prototype with Metasfresh and see if the product fits my needs.

Use case is about using rest-api in order to complete following actions (found one from metasfresh WEBAPI module) :

  • create a customer (first name, name, email… basic personnal informations).
  • add an appointment to this customer (agenda)
  • attach payment transaction to this customer (save amount, payment method, date…) (payment will be process by paypal)
  • customer can read it’s own informations and edit it
  • application send email to customer after payment is saved into metasfresh

I don’t need the front end from Metasfresh as there will be a cutsom one from my company.

What I did :

  • I started with metasfresh-docker project and I can run it successfully on ubuntu server.
  • I created a user manually and configured it with english langage.
  • I can access swagger-ui documentation from http://my-server:8080/swagger-ui.html
  • I can log in from login-rest-controller ->/rest/api/login/authenticate

What I don’t get is :

  • How can I perform CRUD operation on my customer
  • how can I perform CRUD operation on my customer’s agenda
  • how can I send email to my customer on specific actions (payment saved)

Technical issues :

  • can’t find swagger documentation
  • can’t find payload classes from swagger-ui, for example can’t find JSONEmailRequest.java from github repository (https://github.com/metasfresh/metasfresh)
  • can’t find source code for controllers I need

Would be very nice to point me in the good direction for those issues !

Thx you