Definition:

Webservice is a connector used to send data with other web applications.

Icon:

1667487132740-653.png

Configuration:

There is 2 parts in configuring of the webservice connector:

  • Configuring the Webservice in the ConfigurationCOM menu:

     

1667487261988-482.png

In order to use the Webservice, you have first to configure it in the ConfigurationCOM menu in the portal in the distant tab. This configuration is unique to the environment, and cannot be reused in another environment.   

1667487553991-372.png

There are many parameters to configure for the WebService connector:

  • Name: The name of the distant Webservice used
  • IP/host: The domain name of the server or the IP address used
  • URI: The path in the IP/host used to send the files
  • Method: signifies the method used to get the data( GET, POST, PUT, DELETE)
  • Port: The port of the listening
  • Protocol: The protocole used (HTTP ou HTTPS)
  • Authentification Mode: There is 2 different ways for the authentification mode
    • Basic: is a mode that needs 3 attributes(header: the header'name, user encoded in base64, password encoded in base64)
    • Token: is a mode that consists on putting a token in the header. This mode uses 2 parameters: The header and the token is an encoded and encrypted data with a unique key using the HASHMAC algorithm.
  • Timeout: is the max time acceptable to connect to the WS and get the result.
  • Charset: is the encodage of the json file that will be sent to WS and of the result file
  • Configuring the Webservice connector in the scenario:

     

Second, you have to configure the connector in the Scenario menu.

1667492134946-717.png

For this configuration, you have to fill these parameters:

  • Destinataire: The environment where the distant configuration exists
  • Config: The name of the distant configuration in the chosen environment
  • Dyn.enveloppe: is a Yes or No value that mentions if the enveloppe is dynamic
  • Enveloppe: if the enveloppe is fixed, this parameter is for uploading the enveloppe file or the connector's name that contains the file and if it is dynamic, you mention the connector's name that contains the enveloppe.
  • Data: the connector's name that contains the data
  • Output FileName: The output file name 

Elements of the WS:

  • The enveloppe:

    It contains the enveloppe of the informations that will be transferred to the WS.

    The enveloppe can be linked to the message data in this way.

    • %DATA% : Le content of the file mentionned in the parameter DATA will the same in the message
    • %DATA64% : the message file linked to DATA will be encoded in base 64 and inserted
    • %DATAZIP% : the message file linked to DATA will be zipped and inserted
    • %DATAZIP64% : the message file linked to DATA will be encoded in base 64 and zipped then inserted

    Note: The enveloppe may be:

    • uploaded in the enveloppe parameter of the WS as a file or as a connector name that contains the file
    • inserted with a reference to the message 

     

  • The message:

    It contains the content of the message that will be transferred to the WS, it will be inserted inside the enveloppe of the connector. The message can be uploaded dynamically using the elements of the scenario or can be fixed and uploaded inside the WS connector. 

     

Example:

  • Scenario:

1667577279879-137.png

  • Enveloppe: When using %DATA64% or %DATAZIP64% you need to add the "" to the enveloppe.

1667577352836-357.png

The enveloppe can sometimes only have %DATA% in its context.

  • Result: is the encoded file that exists in the connector FileDetection1 in base 64.

1667579240866-555.png

Tags:
    
This wiki is hosted and managed by iXPath
Powered by XWiki 13.3 debian