# Variable access with web services

**URL:** <https://tech-community.robotics.abb.com/t/variable-access-with-web-services/7570>\
**Category:** RobotStudio\
**Created:** [February 10, 2017, 7:21am UTC](https://tech-community.robotics.abb.com/t/variable-access-with-web-services/7570 "2017-02-10T07:21:52Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![GMORRIS59](https://avatars.discourse-cdn.com/v4/letter/g/e68b1a/32.png) [@GMORRIS59](https://tech-community.robotics.abb.com/u/GMORRIS59)\
**Post date:** [February 10, 2017, 7:21am UTC](https://tech-community.robotics.abb.com/t/variable-access-with-web-services/7570/1 "2017-02-10T07:21:52Z")

</div>

I am trying to read a program user variable in Module 1  
PERS num count := 0;

The manual states that I should be able to

```auto
curl --digest -u "Default User":robotics [http://192.168.8.105/rw/rapid/symbol/data/RAPID/T_ROB1/user/count](http://192.168.8.105/rw/rapid/symbol/data/RAPID/T_ROB1/user/reg1)

```

But first of all I think it should be symbols and symbol is not known with resource not found.

So I have tried

```auto
/:[c:\temp]curl --digest -u "Default User":robotics "http://127.0.0.1/rw/rapid/s
ymbols?action=show" | xmllint-1.0.exe

```

---

<div class="post-metadata">

**Author:** ![John\_Verheij](https://dub1.discourse-cdn.com/flex005/user_avatar/tech-community.robotics.abb.com/john_verheij/32/1724_2.png) [@John\_Verheij](https://tech-community.robotics.abb.com/u/John_Verheij)\
**Post date:** [February 10, 2017, 10:42am UTC](https://tech-community.robotics.abb.com/t/variable-access-with-web-services/7570/2 "2017-02-10T10:42:52Z")

</div>

It should be “symbol” and not “symbols”. This is the Rapid Code:

```auto

MODULE Module1

  

  PERS num count := 13746;

  

ENDMODULE

```

This is the command to read the value:

```auto
curl --digest -u "Default User":robotics http://localhost/rw/rapid/symbol/data/RAPID/T_ROB1/Module1/count

```

And this is the result:

```auto
<?xml version="1.0" encoding="UTF-8"?>
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title>rapid</title>
    <base href="http://localhost:80/rw/rapid/"/>
  </head>
  <body> 
    <div class="state">
      <a href="symbol/data/RAPID/T_ROB1/Module1/count" rel="self"></a>
      <a href="symbol/data/RAPID/T_ROB1/Module1/count?action=show" rel="action"></a>
      <ul>
        <li class="rap-data" title="RAPID/T_ROB1/Module1/count"> 
          <span class="value">13746</span>
        </li>
      </ul>
    </div>
  </body>
</html>

```
