Skip to content

Commit 4165acc

Browse files
authored
Change version wording
1 parent 47cd100 commit 4165acc

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

  • content/en/docs/refguide10/modeling/integration/rest-services/published-rest-services/published-rest-service

content/en/docs/refguide10/modeling/integration/rest-services/published-rest-services/published-rest-service/_index.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,17 +69,18 @@ If authentication is required, you can select which authentication methods to su
6969
* Select **Active session** to allow access from JavaScript inside your current application
7070
* Once a user has logged into the browser, the JavaScript in your app can access the REST service using the current user's session
7171
* [Offline-first](/refguide10/offline-first/) apps cannot use active session authentication, because they do not have sessions that stay active while the app is running
72-
* To prevent cross-site request forgery, the `X-Csrf-Token` header needs to be set on each request. If you're using a JS action, you need can use our API to retrieve the token.
72+
* To prevent cross-site request forgery, the `X-Csrf-Token` header needs to be set on each request. If you are using a JavaScript action, you can use an API to retrieve the token.
7373

74-
Example for Mendix versions below 10.23:
74+
For Studio Pro versions 10.22 and below, see the following example:
7575

7676
```javascript
7777
var xmlHttp = new XMLHttpRequest();
7878
xmlHttp.open("GET", "http://mysite/rest/myservice/myresource", false);
7979
xmlHttp.setRequestHeader("X-Csrf-Token", mx.session.getConfig("csrftoken"));
8080
xmlHttp.send(null);
8181
```
82-
Example for Mendix versions 10.23 and newer:
82+
83+
For Studio Pro versions 10.23 and above, see the following example:
8384

8485
```javascript
8586
import getCSRFToken from "mx-api/session";

0 commit comments

Comments
 (0)