Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sessions's expiresAt is returned as a string instead of Date object #776

Closed
drew-gross opened this issue Mar 3, 2016 · 2 comments
Closed
Assignees
Labels
type:bug Impaired feature or lacking behavior that is likely assumed

Comments

@drew-gross
Copy link
Contributor

@nlutsenko let me know if you are starting on this, if you don't I will start on it when I wrap up other dashboard stuff.

Steps to reproduce

Getting a session on Parse.com

curl -X GET \
-H "X-Parse-Application-Id: some parse.com app id" \
-H "X-Parse-Master-Key: some parse.com master key" \
https://api.parse.com/1/classes/_Session/XXXXXXX

Result for my app:

{
    "createdAt": "2016-01-03T00:45:43.417Z",
    "createdWith": {
        "action": "login",
        "authProvider": "facebook"
    },
    "expiresAt": {
        "__type": "Date",
        "iso": "2017-01-07T18:02:55.582Z"
    },
    "installationId": "f0743e6a-0fb3-c216-6dc5-3e0bc8ed34e7",
    "objectId": "DduCjDcmR7",
    "restricted": false,
    "sessionToken": "r:ERsvDtKakO7ApMZbCrHs8ZL7i",
    "updatedAt": "2016-01-08T18:02:55.594Z",
    "user": {
        "__type": "Pointer",
        "className": "_User",
        "objectId": "HQcObQVs2d"
    }
}

Getting a session on Parse Server

curl -X GET \
-H "X-Parse-Application-Id: some parse server app id" \
-H "X-Parse-Master-Key: some parse server master key" \
http://localhost:1337/1/classes/_Session/XXXXXX

Result for my app:

{
    "objectId": "NJQZMpCRsx",
    "sessionToken": "r:1868be09b472699e68f554f5ad1ee527",
    "user": {
        "__type": "Pointer",
        "className": "_User",
        "objectId": "rQmfhg5yGB"
    },
    "createdWith": {
        "action": "login",
        "authProvider": "password"
    },
    "restricted": false,
    "expiresAt": "2017-03-02T02:26:28.312Z",
    "updatedAt": "2016-03-02T02:26:28.313Z",
    "createdAt": "2016-03-02T02:26:28.313Z"
}
@drew-gross drew-gross added the type:bug Impaired feature or lacking behavior that is likely assumed label Mar 3, 2016
@drew-gross drew-gross assigned nlutsenko and drew-gross and unassigned nlutsenko Mar 3, 2016
@drew-gross
Copy link
Contributor Author

I'm going to take this over since I've finished my other dashboard stuff.

@nlutsenko
Copy link
Contributor

Sounds good, I am still stuck with before/after save stuff.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Impaired feature or lacking behavior that is likely assumed
Projects
None yet
Development

No branches or pull requests

2 participants