# Authenticate using Access Token

**URL:** <https://datashield.discourse.group/t/authenticate-using-access-token/132>\
**Category:** Developer support\
**Created:** [21 October 2019 12:39 UTC](https://datashield.discourse.group/t/authenticate-using-access-token/132 "2019-10-21T12:39:42Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jgruendner](https://yyz2.discourse-cdn.com/free1/user_avatar/datashield.discourse.group/jgruendner/32/15_2.png) [@jgruendner](https://datashield.discourse.group/u/jgruendner)\
**Post date:** [21 October 2019 12:39 UTC](https://datashield.discourse.group/t/authenticate-using-access-token/132/1 "2019-10-21T12:39:42Z")

</div>

Hi All,

I am currently trying to connect to Opal using personal access tokens in DataSHIELD.

It seems that the function does not work as described in the wiki: [http://opaldoc.obiba.org/en/latest/web-user-guide/my-profile.html#my-profile](http://opaldoc.obiba.org/en/latest/web-user-guide/my-profile.html#my-profile)

Trying to login to my opal (without DataSHIELD) I get the following error message:

Error in opal.login(token = “ktNaW6bDehjXZuRmR0EQlJxweCFyUX”, url = “[https://opal-url:443](https://opal-url/)”) : unused argument (token = “ktNaW6bDehjXZuRmR0EQlJxweCFyUX”)

Further i am not sure how to use the token in the datashield.login function, as the documentation does not show how a token can be used: [https://cran.datashield.org/web/opal/datashield.login.html](https://cran.datashield.org/web/opal/datashield.login.html)

---

<div class="post-metadata">

**Author:** ![yannick](https://yyz2.discourse-cdn.com/free1/user_avatar/datashield.discourse.group/yannick/32/19_2.png) [@yannick](https://datashield.discourse.group/u/yannick)\
**Post date:** [21 October 2019 13:01 UTC](https://datashield.discourse.group/t/authenticate-using-access-token/132/2 "2019-10-21T13:01:09Z")

</div>

Hi Julian,

Are you using Opal server 2.15 and opal R client [**opalr**](https://cran.r-project.org/package=opalr) 1.2 ?

Note that the legacy **opal** R client does not support this feature. Same thing for the current DataSHIELD release (which is based on **opal** R client). The next DataSHIELD major version will be based on DSI, which will handle the token based authentication ( **opal** R client will be deprecated in favor of **opalr** ).

Cheers, Yannick

---

<div class="post-metadata">

**Author:** ![jgruendner](https://yyz2.discourse-cdn.com/free1/user_avatar/datashield.discourse.group/jgruendner/32/15_2.png) [@jgruendner](https://datashield.discourse.group/u/jgruendner)\
**Post date:** [21 October 2019 13:24 UTC](https://datashield.discourse.group/t/authenticate-using-access-token/132/3 "2019-10-21T13:24:11Z")

</div>

> [@yannick](#):
>
> e thing for the current DataSHIELD release (which is based on **opal** R clien

Hi Yannick,

thank you for the quick reply. I was using the opal I installed as part of my DataSHIELD setup, so the legacy version.

I will wait for the next major version then.

Regards,

Julian

---

<div class="post-metadata">

**Author:** ![yannick](https://yyz2.discourse-cdn.com/free1/user_avatar/datashield.discourse.group/yannick/32/19_2.png) [@yannick](https://datashield.discourse.group/u/yannick)\
**Post date:** [21 October 2019 13:26 UTC](https://datashield.discourse.group/t/authenticate-using-access-token/132/4 "2019-10-21T13:26:10Z")

</div>

DSI switch is due by the end of this year according to DataSHIELD’s road map.

Yannick
