Skip to content

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

Description

@drew-gross

@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"
}

Activity

  1. added
    type:bugImpaired feature or lacking behavior that is likely assumed
    on Mar 3, 2016
  2. drew-gross commented on Mar 3, 2016

    @drew-gross
    ContributorAuthor

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

  3. nlutsenko commented on Mar 3, 2016

    @nlutsenko
    Contributor

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

  4. added a commit that references this issue on Mar 3, 2016
    df40220
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

type:bugImpaired feature or lacking behavior that is likely assumed

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions