# Programmatically logging into ODK central and managing User-Store/ Session

**URL:** <https://forum.getodk.org/t/programmatically-logging-into-odk-central-and-managing-user-store-session/40188>\
**Category:** Development\
**Created:** [January 20, 2023, 4:11pm UTC](https://forum.getodk.org/t/programmatically-logging-into-odk-central-and-managing-user-store-session/40188 "2023-01-20T16:11:05Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Matthew\_White](https://getodk.b-cdn.net/user_avatar/forum.getodk.org/matthew_white/32/1654_2.png) [@Matthew\_White](https://forum.getodk.org/u/Matthew_White)\
**Post date:** [January 20, 2023, 6:40pm UTC](https://forum.getodk.org/t/programmatically-logging-into-odk-central-and-managing-user-store-session/40188/2 "2023-01-20T18:40:56Z")

</div>

Hi @Vishnu_Prasath! The login flow in the Central frontend relies on the cookie returned by POST /v1/sessions. When the user first visits the frontend, the Vue router will generally redirect them to the login page unless it is able to use the cookie to identify an existing login. However, the API docs [recommend](https://odkcentral.docs.apiary.io/#reference/authentication/session-authentication/logging-in) not relying on that cookie. We don't consider the cookie part of the stable API, so any aspect of it may change. Currently, the cookie is "domain-locked" because its name includes the `__Host-` prefix.

If you're reading code in the frontend, note that src/util/session.js contains relevant code. Note though that we don't make guarantees about the behavior of the frontend. Developers should consider the API the stable interface.

> [@Vishnu\_Prasath](#):
>
> There has been some discussion on the Single-sign-on , any new ideas on this

There's been some recent discussion about SSO [here](https://forum.getodk.org/t/sso-oauth2-saml-in-central/38804). We haven't had any new updates since then, but please feel free to continue checking in about our plans related to SSO.

---

_[View the full topic](https://forum.getodk.org/t/programmatically-logging-into-odk-central-and-managing-user-store-session/40188)._
