mirror of
https://github.com/subutux/rmapy.git
synced 2025-12-08 22:53:25 +00:00
Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
45485d4dbf | ||
|
|
8916261afd | ||
|
|
081db1ddc2 | ||
|
|
5c78598271 |
@@ -7,7 +7,7 @@ are re-used because we use the same storage location & format.
|
||||
If not, you'll need to register the client as a new device on `my remarkable`_.
|
||||
|
||||
|
||||
.. _my remarkable: https://my.remarkable.com/connect/remarkable
|
||||
.. _my remarkable: https://my.remarkable.com/device/desktop/connect
|
||||
|
||||
.. _rmapi: https://github.com/juruen/rmapi
|
||||
|
||||
@@ -30,6 +30,7 @@ and use the code you see on the webpage
|
||||
# This registers the client as a new device. The received device token is
|
||||
# stored in the users directory in the file ~/.rmapi, the same as with the
|
||||
# go rmapi client.
|
||||
# Get a token at https://my.remarkable.com/device/desktop/connect.
|
||||
rmapy.register_device("fkgzzklrs")
|
||||
# It's always a good idea to renew the user token every time you start
|
||||
# a new session.
|
||||
|
||||
@@ -95,12 +95,12 @@ class Client(object):
|
||||
"""Registers a device on the Remarkable Cloud.
|
||||
|
||||
This uses a unique code the user gets from
|
||||
https://my.remarkable.com/connect/remarkable to register a new device
|
||||
or client to be able to execute api calls.
|
||||
https://my.remarkable.com/device/desktop/connect to register
|
||||
a new device or client to be able to execute api calls.
|
||||
|
||||
Args:
|
||||
code: A unique One time code the user can get
|
||||
at https://my.remarkable.com/connect/remarkable .
|
||||
at https://my.remarkable.com/device/desktop/connect.
|
||||
Returns:
|
||||
True
|
||||
Raises:
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
RFC3339Nano = "%Y-%m-%dT%H:%M:%SZ"
|
||||
USER_AGENT = "rmapy"
|
||||
AUTH_BASE_URL = "https://webapp-production-dot-remarkable-production.appspot.com"
|
||||
BASE_URL = "https://document-storage-production-dot-remarkable-production.appspot.com" # noqa
|
||||
DEVICE_TOKEN_URL = "https://webapp-production-dot-remarkable-production.appspot.com/token/json/2/device/new"
|
||||
USER_TOKEN_URL = "https://webapp-production-dot-remarkable-production.appspot.com/token/json/2/user/new"
|
||||
DEVICE_TOKEN_URL = AUTH_BASE_URL + "/token/json/2/device/new"
|
||||
USER_TOKEN_URL = AUTH_BASE_URL + "/token/json/2/user/new"
|
||||
DEVICE = "desktop-windows"
|
||||
SERVICE_MGR_URL = "https://service-manager-production-dot-remarkable-production.appspot.com" # noqa
|
||||
|
||||
2
setup.py
2
setup.py
@@ -37,7 +37,7 @@ setup(
|
||||
# For a discussion on single-sourcing the version across setup.py and the
|
||||
# project code, see
|
||||
# https://packaging.python.org/en/latest/single_source_version.html
|
||||
version='0.3.0', # Required
|
||||
version='0.3.1', # Required
|
||||
|
||||
# This is a one-line description or tagline of what your project does. This
|
||||
# corresponds to the "Summary" metadata field:
|
||||
|
||||
Reference in New Issue
Block a user