Skip to content

Commit 19b6c99

Browse files
author
Johanna Hemminger
committed
Fix links
1 parent d7d6e53 commit 19b6c99

3 files changed

Lines changed: 63 additions & 59 deletions

File tree

content/en/docs/refguide9/modeling/integration/web-services/consumed-web-services/consume-a-complex-web-service.md

Lines changed: 20 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
---
22
title: "Consume a Complex Web Service"
3-
url: /howto9/integration/consume-a-complex-web-service/
3+
url: /refguide9/integration/consume-a-complex-web-service/
44
category: "Integration"
55
weight: 8
66
description: "Describes how to import a web service both directly and using the wizard as well as how to configure a web service call."
77
tags: ["web service", "integration", "consume"]
8+
aliases:
9+
- /howto9/integration/consume-a-complex-web-service/
810
---
911

1012
## 1 Introduction
@@ -27,7 +29,7 @@ To import a web service using the wizard, follow these steps:
2729

2830
1. Open your domain model and click **Import web service/XML file** in the toolbar.
2931

30-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/import-web-service-wizard-button.png" >}}
32+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/import-web-service-wizard-button.png" >}}
3133

3234
This opens the **Import Web Service or XML Schema** wizard that will guide you through importing the result of a web service (or an XML file). As a result, it will generate the following:
3335
* Domain model entities to store the results
@@ -36,29 +38,29 @@ To import a web service using the wizard, follow these steps:
3638
* A microflow that calls the web service (or imports an XML file) (optional)
3739
2. On the **Import Web Service or XML Scheme** dialog box, select **Web service operation** and click **Next**:
3840

39-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/wizard-import-schema.png" alt="wizard banner" >}}
41+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/wizard-import-schema.png" alt="wizard banner" >}}
4042

4143
3. On the **Import Web Service** dialog box, select **Web service operation** and click **Next**.
4244
4. In the **New Web Service Operation** dialog box, for **WSDL source** , specify the WSDL to be used for this imported web service. For the **WSDL source** you can either provide the **URL** (for example, http://webservices.oorsprong.org/websamples.countryinfo/CountryInfoService.wso?WSDL) or load a **File** from your computer.
4345

44-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/wizard-new-operation.png" >}}
46+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/wizard-new-operation.png" >}}
4547

4648
5. Click **Next** to fetch the services and operations in the WSDL.
4749
6. In the **Select Ports** pop-up window select a web service port and click **OK**. Studio Pro now imports the operations.
4850

49-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/port.png" >}}
51+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/port.png" >}}
5052

5153
7. On the **New Web Service Operation** dialog box, you can review the services and operations that are available to the imported web service. If you click on any of the operations, information about the operation will be displayed in the right pane. Select a web service operation and click **Next**.
5254

53-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/wizard-web-service-list.png" alt="wizard web service" >}}
55+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/wizard-web-service-list.png" alt="wizard web service" >}}
5456

5557
8. On the **Select Elements** dialog box, you can optionally select individual elements to map as return values of the web service. Click **Next**.
5658

57-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/wizard-select-elements.png" alt="wizard select elements" >}}
59+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/wizard-select-elements.png" alt="wizard select elements" >}}
5860

5961
9. In the final step of this wizard you can select icons that will be attached to the generated entities and create a microflow in which the imported web service is called:
6062

61-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/wizard-select-icon.png" >}}
63+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/wizard-select-icon.png" >}}
6264

6365
10. Click **Finish** to create the web service.
6466

@@ -71,7 +73,7 @@ When finished the wizard will add the following to your model based on the optio
7173
* A microflow in which the web service operation is called
7274
* Domain model entities (by default, Studio Pro creates non-persistable entities)
7375

74-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/web-service-entity.png" >}}
76+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/web-service-entity.png" >}}
7577

7678
## 3 Importing a Web Service Directly
7779

@@ -83,52 +85,52 @@ To import a web service directly, follow these steps:
8385
2. Specify a name for the new consumed web service and click **OK**.
8486
3. In the **Consumed Web Service** box, specify the **WSDL Source** to be used for this consumed web service. Click **Edit**, and in the **WSDL Source** diaglog box, specify a **URL** or load a **File** from your computer.
8587

86-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/enter-wsdl-url.png" >}}
88+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/enter-wsdl-url.png" >}}
8789

8890
4. Click **Import** to fetch the services and operations in the WSDL. If prompted, in the **WSDL Source** dialog box, select the ports you want to use and click **OK**.
8991

9092
5. In the **Consumed Web Services** screen, review the **Services** and **Operations** available to the imported web service. If you click on any of the **Operations**, information about the operation will be displayed in the right pane. You can select individual web service operations from the list otherwise the whole service and operation will be imported:
9193

92-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/consumed-web-service-doc.png" >}}
94+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/consumed-web-service-doc.png" >}}
9395

9496
## 4 Configuring the Web Service Call
9597

9698
To configure the web service call, follow these steps:
9799

98100
1. If you did not use the web service wizard or did not use the option in the wizard to automatically create a microflow, you have to create a microflow that will call the imported web service:
99101

100-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/import-microflow.png" >}}
102+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/import-microflow.png" >}}
101103

102104
{{% alert color="info" %}}Make sure the microflow either creates the variables required as arguments for the web service call or has them passed to it.{{% /alert %}}
103105

104106
2. If you are creating your own microflow, add the call web service activity to the microflow. For details on how to add activities to a microflow, see [Activities](/refguide9/activities/) in the *Studio Pro Guide*.
105107
3. Double-click the activity to open the **Call Web Service** properties editor and in the **Operation** section, click **Select** for **Operation**.
106108
4. In the **Select Web Service Operation** dialog box, you can select the operation for this web service call:
107109

108-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/select-web-service-op.png" alt="select web service op" >}}
110+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/select-web-service-op.png" alt="select web service op" >}}
109111

110112
5. In the **SOAP Request Body** tab of the **Call Web Service** properties editor, you can configure the SOAP body. This contains the parameters needed to execute the web service request. The **Simple**, **Export Mapping**, and **Custom** options enable you to select the type of SOAP body to use. Click **Edit value** and use one of the following to change the domain-to-XML mapping or the variables from the microflow used as input arguments:
111113
* **Simple expressions for each request parameter** — if the imported web service requires only primitive arguments:
112114

113-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/simple-expression-param.png" >}}
115+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/simple-expression-param.png" >}}
114116

115117
* **Export mappings for each request parameter** or **Export mapping for the entire request** — if the domain model entities need to be mapped to XML elements
116118
* **Custom request template** — for the definition of a custom XML body with parameters:
117119

118-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/custom-request-temp.png" alt="custom-request-temp" >}}
120+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/custom-request-temp.png" alt="custom-request-temp" >}}
119121

120122
6. In the **HTTP Headers** tab, if the Mendix Runtime should use HTTP authentication before calling the web service, check **Use HTTP authentication** and enter the **User name** and **Password** using the **Edit** buttons:
121123

122-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/http-authentication.png" alt="http-authentication" >}}
124+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/http-authentication.png" alt="http-authentication" >}}
123125

124126
7. In the **SOAP Response** tab, you can configure the handling of the return from the web service call as follows:
125127
* If the return is a complex XML structure, select **Mapping** and use an XML-to-domain mapping to map the XML elements to the domain model entities:
126128

127-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/18581790.png" >}}
129+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/18581790.png" >}}
128130

129131
* If the return is a primitive, you can store it in a variable by selecting **Store in variable****Yes** and provide the **Type** and **Variable**:
130132

131-
{{< figure src="/attachments/howto9/integration/consume-a-complex-web-service/18581789.png" >}}
133+
{{< figure src="attachments/refguide9/integration/consume-a-complex-web-service/18581789.png" >}}
132134

133135
* If you want to ignore the return, select **Ignore**
134136
8. Your imported web service is now ready to be used in your application.

content/en/docs/refguide9/modeling/integration/web-services/consumed-web-services/consume-a-simple-web-service.md

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
---
22
title: "Consume a Simple Web Service"
3-
url: /howto9/integration/consume-a-simple-web-service/
3+
url: /refguide9/integration/consume-a-simple-web-service/
44
category: "Integration"
55
weight: 7
66
description: "Describes how to import a WSDL and create logic to call the web service."
77
tags: ["integration", "wsdl", "web service", "consume"]
8+
aliases:
9+
- /howto9/integration/consume-a-simple-web-service/
810
---
911

1012
## 1 Introduction
@@ -29,11 +31,11 @@ To import a WSDL, follow these steps:
2931
3. On the **Consumed Web Service** screen. Click **Edit**. Enter `https://www.w3schools.com/xml/tempconvert.asmx?wsdl` as the **URL** and click **Import**.
3032
4. The **Select Ports** dialog box is displayed for selecting a web service port:
3133

32-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582065.png" >}}
34+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582065.png" >}}
3335

3436
5. Click **OK** to select the default, and click **OK** to close the **WSDL Source** dialog. The operations **CelsiusToFahrenheit** and **FahrenheitToCelsius** are imported into the app:
3537

36-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582084.png" >}}
38+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582084.png" >}}
3739

3840
## 3 Creating Logic to Call the Web Service
3941

@@ -42,55 +44,55 @@ To create logic to call the web service, follow these steps:
4244
1. Right-click your module in the **App Explorer** and select **Add microflow** from the menu:
4345
2. Enter a name for the new microflow: *ConvertCelsiusToFahrenheit* and click **OK**.
4446

45-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582083.png" >}}
47+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582083.png" >}}
4648

4749
3. An empty microflow will be displayed:
4850

49-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582081.png" >}}
51+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582081.png" >}}
5052

5153
4. Open the **Toolbox** and drag a **Create variable** activity to the line between the start and end event.
5254
5. Double-click the new activity to open the **Create Variable** properties editor.
5355
6. For the **Data Type**, select **Integer/Long** and enter *100* as the value. For the **Output Variable Name** enter *TemperatureInCelsius*:
5456

55-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582080.png" >}}
57+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582080.png" >}}
5658

5759
7. Click **OK.** The microflow will look like this:
5860

59-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582079.png" >}}
61+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582079.png" >}}
6062

6163
8. Drag a **Call web service** activity from the toolbox and add it to the microflow just before the end event.
6264
9. Double-click this activity to open the **Call Web Service** properties editor. For the **Operation** of your consumed web service, click **Select**. Expand the **TemperatureConverter** web service and under **TempConvert** click **CelsiusToFahrenheit** and click **Select**:
6365

64-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582076.png" >}}
66+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582076.png" >}}
6567

6668
10. In the **Location** section for this operation , check the **Override location** box to override the location and use the secure location of the web service.
6769
11. Click **Edit** and change `http` to `https` for the URL in the **Location** editor and click **OK**.
6870
12. In the **SOAP Request Body** tab of the **Call Web Service** properties editor, double-click the **Celsius (optional)** input parameter and enter `toString($TemperatureInCelsius)` for the expression. The web service operation expects a string value, which is why you need to use the `toString` function. Then click **OK**.
6971

70-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582075.png" >}}
72+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582075.png" >}}
7173

7274
13. In the **SOAP Response** tab, select **Yes** for the **Store in variable** option. Enter *TemperatureInFahrenheit* for the **Variable name**:
7375

74-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/call-web-serv-SOAP-resp.png" >}}
76+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/call-web-serv-SOAP-resp.png" >}}
7577

7678
14. Click **OK**. The microflow will look like this:
7779

78-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582073.png" >}}
80+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582073.png" >}}
7981

8082
15. Drag a **Show message** activity from the **Toolbox** to the line before the end event.
8183
16. Double-click the new activity to open the **Show Message** dialog box.
8284

8385
17. Select **Information** as the **Type**, and enter *The temperature in Fahrenheit is: {1}* for the **Template**. The *{1}* functions as a placeholder for the parameters.
8486

85-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582071.png" >}}
87+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582071.png" >}}
8688

8789
18. Create a new parameter and enter `$TemperatureInFahrenheit` for the expression (this is the return value of the web service operation) and click **OK**:
8890

89-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582072.png" >}}
91+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582072.png" >}}
9092

9193
19. Click **OK** again to save the show message activity values. The microflow now looks like this:
9294

93-
{{< figure src="/attachments/howto9/integration/consume-a-simple-web-service/18582070.png" >}}
95+
{{< figure src="attachments/refguide9/integration/consume-a-simple-web-service/18582070.png" >}}
9496

9597
20. Create a menu item that triggers this microflow. For details on how to create a menu item, see [Setting Up Navigation](/refguide9/setting-up-the-navigation-structure/).
9698

@@ -99,8 +101,8 @@ To create logic to call the web service, follow these steps:
99101
## 4 Read More
100102

101103
* [Create a Secure App](/howto9/security/create-a-secure-app/)
102-
* [Consume a Complex Web Service](/howto9/integration/consume-a-complex-web-service/)
104+
* [Consume a Complex Web Service](/refguide9/integration/consume-a-complex-web-service/)
103105
* [Export XML Documents](/howto9/integration/export-xml-documents/)
104106
* [Import Excel Documents](/howto9/integration/importing-excel-documents/)
105-
* [Expose a Web Service](/howto9/integration/expose-a-web-service/)
107+
* [Expose a Web Service](/refguide9/integration/expose-a-web-service/)
106108
* [Use Selenium Support](/howto9/integration/selenium-support/)

0 commit comments

Comments
 (0)