1

I am using parsepy as a wrapper for parse.com. I have a parse.com table called Player with objects that are linked by a one-to-one relationship using a pointer to a User object. The Player objects have ACL's allowing Public Read but not Public Write, and allows read and write by the user object with which it is linked.

Without passing a Session Token, parse.com returns an error when trying to write to the Player object, since Public write is not allowed by the Player object ACL. Using parsepy, how do I allow a user to write to their Player object? Is there a way to pass the user's Session Token to a parsepy save()?

mcastle
  • 2,882
  • 3
  • 25
  • 43

1 Answers1

1

Taking the example from parsepy documentation:

u = User.login('dhelmet', '12345')
token = u.sessionToken

with SessionToken(token):
    collectedItem = CollectedItem.Query.get(type="Sword")
    collectedItem.name = "katana"
    collectedItem.save()
sreenivas
  • 2,067
  • 1
  • 19
  • 29