Matheus Lima
0508824702
Starting to implement the stripe integration
2019-03-13 21:21:52 -03:00
Chris Veilleux
ca415c9ce3
new name for location table
2019-03-13 17:06:26 -05:00
Matheus Lima
7fc2a54ab0
Created PATCH request to update membership
2019-03-13 18:19:13 -03:00
Matheus Lima
f02d1f151e
Implemented stripe integration
2019-03-09 00:32:09 -03:00
Chris Veilleux
10b7ea675a
added endpoint to get membership types and the supporting repository logic
2019-03-08 17:27:45 -06:00
Chris Veilleux
ae27dd0777
removed unused module
2019-03-08 16:57:56 -06:00
Matheus Lima
5ebad16060
Starting to implement the stripe integration
2019-03-08 19:37:45 -03:00
Matheus Lima
8484d8289b
- Changing the validation in the endpoints used to update the device fields and to activate the device and to upload the skill settings
...
- Checking the authentication token in the before_request function. This is a tricky to make the api compatible with the mycroft core is expecting today. Today tartarus returns 401 when it calls and endpoint with a non existent path (like /device/{uuid} without pass the uuid). That is the value core expect to check if it needs to perform a device pairing. We should change that in future versions
- Changed device endpoint to send the user uuid together with the device
2019-03-08 17:09:53 -03:00
Matheus Lima
e8fc54d657
Moved logic related to create a device login session to a python function, allowing it being used by the creating and refreshing token endpoint and by the behavioral tests
2019-03-06 21:31:49 -03:00
Matheus Lima
c44284fbef
Implemented authentication mechanism for the public API
2019-03-06 18:15:45 -03:00
Matheus Lima
a4ecbae369
Moving the cache instance to the PublicEndpoint class
2019-03-06 17:11:16 -03:00
Matheus Lima
fe8466a309
Created test to validate that when we update the skills settings, the device API is able to fetch the skill settings with the new values
2019-03-06 16:42:57 -03:00
Matheus Lima
c1f0e70980
Created test to validate that when we update the skills settings, the device API is able to fetch the skill settings with the new values
2019-03-06 15:35:35 -03:00
Matheus Lima
b85809f316
Implemented skill uploading
2019-03-06 15:35:35 -03:00
Matheus Lima
13e64340e9
Storing skill identifier in to settings_display from the skill.setting_display table
2019-03-06 15:35:35 -03:00
Chris Veilleux
37c94f1adc
squashed bug where we tried to encrypt a non-existent password for federated logins
2019-03-06 11:40:54 -06:00
Chris Veilleux
84965186dc
added geography endpoint and the repository code to support it
2019-03-05 16:04:38 -06:00
Chris Veilleux
1bfa7800c5
added voice endpoint and the repository code to support it
2019-03-05 15:43:32 -06:00
Chris Veilleux
a039bcfb0e
new endpoint to manage wake words and the repository changes to support it
2019-03-05 15:23:24 -06:00
Chris Veilleux
a16bdae969
new account api endpoint to retreive account preferences, along with the necessary repository changes
2019-03-05 15:22:09 -06:00
Chris Veilleux
ac7f1cb593
added device endpoint to account api and altered repository to serve it data
2019-03-05 15:20:31 -06:00
Chris Veilleux
e3d42d3aca
ui is expecting a value in the membership type even if the user has no membership
2019-03-04 14:41:56 -06:00
Chris Veilleux
169d026db9
fixed a missing None check bug
2019-03-04 14:37:13 -06:00
Chris Veilleux
5f03a3c135
fixed a bug where no the account.agreements attribute was None if there were no agreements. now set to empty list
2019-03-04 14:31:37 -06:00
Chris Veilleux
91a77c5720
added sslmode to connection config to support DigitalOcean database hosting
2019-03-04 00:44:53 -06:00
Chris Veilleux
59872f4d24
socket change
2019-03-04 00:43:56 -06:00
Matheus Lima
a5dcdf0c94
Applying model changes
2019-03-03 22:46:00 -03:00
Matheus Lima
a90833f178
Fixing tests after rebase
2019-03-03 22:46:00 -03:00
Matheus Lima
737167b854
Fixed skill endpoints applying the changes related to the skill settings model.
2019-03-03 22:46:00 -03:00
Chris Veilleux
581bf1812d
renamed a few items in the database schema
2019-03-01 20:33:35 -06:00
Chris Veilleux
0d6cb7d3f1
resolve merge conflicts
2019-02-28 22:01:21 -06:00
Chris Veilleux
e16369c565
added snake_to_camel import
2019-02-28 21:47:04 -06:00
Chris Veilleux
3c5983a194
added repository method to get the number of devices for an account.
2019-02-28 21:46:32 -06:00
Chris Veilleux
35fa76e6a2
refactored how skill settings are retrieved. added skill settings change code
2019-02-28 21:46:05 -06:00
Chris Veilleux
c3608a10bf
Merge pull request #56 from MycroftAI/populate-profile-page
...
Populate profile page
2019-02-28 20:44:22 -06:00
Chris Veilleux
61e884b0f6
implemented a sql trick to group by json that made the code a lot simpler
2019-02-26 14:09:31 -06:00
Chris Veilleux
638b74206d
added some logic on how to determine the skill name displayed in the ui
2019-02-26 09:37:56 -06:00
Chris Veilleux
1b7c382846
new repository for account skills
2019-02-25 23:27:04 -06:00
Chris Veilleux
05bf20ac4d
fixed a minor bug when an account has no refresh tokens
2019-02-25 23:25:37 -06:00
Matheus Lima
eccb83ed44
- Refactoring to use a AccountRepository to get an account using the device id
...
- Created tests for the metrics service
2019-02-25 19:03:08 -03:00
Matheus Lima
edc43ed39a
Created endpoint to communicate with metrics service
2019-02-25 16:42:11 -03:00
Chris Veilleux
6661f27caf
resolve merge conflict
2019-02-25 13:33:50 -06:00
Matheus Lima
2ae8b408e2
adding TODO to change return in the API v2
2019-02-25 16:28:14 -03:00
Matheus Lima
e722e519bf
Fixed the endpoint used to get the subscription type of a device and created tests for this endpoint
2019-02-25 16:28:14 -03:00
Matheus Lima
88aaccd073
Adding test for the device setting endpoint
2019-02-25 16:28:14 -03:00
Matheus Lima
588525ea47
Created test to the endpoint used to fetch a device
2019-02-25 16:28:14 -03:00
Chris Veilleux
cede611f0f
Merge remote-tracking branch 'remotes/origin/tartarus-overhaul' into populate-profile-page
2019-02-25 12:06:22 -06:00
Chris Veilleux
42975024aa
new package for re-usable testing code. first addition is some database setup and teardown logic
2019-02-25 01:58:41 -06:00
Chris Veilleux
02a9242c17
new base class for data repositories to eliminate some boilerplate code
2019-02-25 01:57:44 -06:00
Chris Veilleux
73fca3b7e1
added membership repository
2019-02-25 01:50:20 -06:00
Chris Veilleux
f63d1ad633
added membership repository
2019-02-25 01:49:56 -06:00
Chris Veilleux
86883f31aa
added non-pool connection to API
2019-02-25 01:48:35 -06:00
Chris Veilleux
d71ae4831c
moved database connection call into the get_base_config function so it is not attempted at import time. this is necessary to allow the behave tests to create a test database
2019-02-25 01:48:02 -06:00
Chris Veilleux
95a5d383e9
changed "subscription" to "membership"
2019-02-25 01:46:43 -06:00
Chris Veilleux
20e865d6ab
changed "subscription" to "membership"
2019-02-25 01:46:29 -06:00
Chris Veilleux
8d73d18e09
changed "subscription" to "membership"
2019-02-24 23:54:34 -06:00
Chris Veilleux
e633ade60d
changed "subscription" to "membership"
2019-02-24 23:49:12 -06:00
Chris Veilleux
0c1e7ec9d8
changed "subscription" to "membership"
2019-02-24 23:47:19 -06:00
Matheus Lima
577c470d90
- Using schematics to validate POST data
...
- Fixed test
- Fixed error handler to present a better error message
2019-02-22 14:23:43 -03:00
Matheus Lima
af45f633d1
Created endpoint to send email to the account associated to a device
2019-02-22 14:23:43 -03:00
Chris Veilleux
72db7b96eb
added logic to format date fields the way the UI likes it
2019-02-21 23:12:14 -06:00
Chris Veilleux
7116ae62d3
removed validtor-collection from requirements
2019-02-20 17:34:59 -06:00
Chris Veilleux
57d46dcd09
Merge remote-tracking branch 'remotes/origin/tartarus-overhaul' into account-api
2019-02-20 17:32:52 -06:00
Chris Veilleux
a2a4b4e834
added checks to auth token refresh test to address bug.
2019-02-20 17:31:49 -06:00
Matheus Lima
f978ca5239
Reverting change in the agreement repository
2019-02-20 20:25:21 -03:00
Matheus Lima
23e056ca96
Created test to validate device pairing workflow
2019-02-20 20:25:21 -03:00
Matheus Lima
640f08ffbe
Refactoring
2019-02-20 20:25:21 -03:00
Matheus Lima
750921fb7d
Created endpoint to activate a device that is in a pairing process
2019-02-20 20:25:21 -03:00
Matheus Lima
5b6776c92e
- Created endpoint to add a device to an account using a pairing code
...
- Renamed selene_cache module to cache
2019-02-20 20:25:21 -03:00
Matheus Lima
64e513a7df
Created endpoint to get the device pairing code
2019-02-20 20:25:21 -03:00
Chris Veilleux
f1e1ba60d1
fixed a bug with authentication logic that refreshed tokens when access token expired
2019-02-20 16:50:22 -06:00
Chris Veilleux
24faf0fbbd
fixed a bug with new account logic when a user opts out of membership
2019-02-20 14:45:06 -06:00
Chris Veilleux
afcbbc05a5
changed display name to username
2019-02-19 17:16:19 -06:00
Chris Veilleux
517177078c
return a dictionary instead of a string to make the response go through the coersion routine
2019-02-19 14:41:05 -06:00
Chris Veilleux
c4919b155b
Merge remote-tracking branch 'remotes/origin/tartarus-overhaul' into account-api
2019-02-19 14:01:34 -06:00
Chris Veilleux
e8a0a161d3
fixing token authentication bugs
2019-02-19 13:33:06 -06:00
Chris Veilleux
b98f667f30
refactored to build access and refresh tokens independently for re-usability in other tests.
2019-02-19 13:31:58 -06:00
Chris Veilleux
8118c1b05c
new error handler for authentication errors
2019-02-19 10:58:48 -06:00
Matheus Lima
6c25c2f85d
Migrating the project from flask-restful to flask
2019-02-19 10:06:30 -03:00
Chris Veilleux
c2dfa9c318
removed the validator-collection package now that we are using schematics
2019-02-18 14:50:05 -06:00
Chris Veilleux
988a70752b
jsonified the response object
2019-02-18 14:43:26 -06:00
Chris Veilleux
b5b7cfdef0
added some whitespace to make pylint happy
2019-02-18 13:01:17 -06:00
Chris Veilleux
ee5731d86e
applied code review corrections
2019-02-18 11:12:06 -06:00
Chris Veilleux
8e62fc8b72
removed old version of response formatter
2019-02-15 22:13:55 -06:00
Chris Veilleux
24875c9e98
removed flask-restful
2019-02-15 21:48:03 -06:00
Chris Veilleux
f5fb8b6dfe
added blueprint for flask application setup common to all selene api's
2019-02-15 21:43:59 -06:00
Chris Veilleux
21ae4511b9
converted from flask-restful to flask
2019-02-15 21:43:13 -06:00
Chris Veilleux
8c2eb61aa1
simplified module name and converted from flask-restful to flask
2019-02-15 21:42:44 -06:00
Chris Veilleux
11693be534
created and endpoints package to group common endpoints
2019-02-15 21:41:51 -06:00
Chris Veilleux
8130f587b2
no need for an error message if we are adding agreements
2019-02-15 21:38:53 -06:00
Chris Veilleux
7666227802
added schematics library
2019-02-15 01:02:22 -06:00
Chris Veilleux
1605d8f33d
fixed a bug where passing a nested dictionary to a dataclass constructor did not build the child data objects correctly
2019-02-15 00:45:23 -06:00
Chris Veilleux
0d3313041e
changed to use new class signature
2019-02-15 00:11:38 -06:00
Chris Veilleux
cefbb22d05
add IDs to dataclasses for account object
2019-02-15 00:10:42 -06:00
Chris Veilleux
eaabe37c5c
ensure the subquery only returns one row
2019-02-15 00:10:11 -06:00
Chris Veilleux
16f676c2f1
include the agreement ID in the agreement object
2019-02-15 00:07:10 -06:00
Chris Veilleux
4f2e0f5274
refactored to take an account id instead of account object as the id is the only field in the object used
2019-02-15 00:06:25 -06:00
Chris Veilleux
49d43d061d
new agreements endpoint
2019-02-12 11:17:19 -06:00
Chris Veilleux
0f0ede9d50
added a repository for agreements
2019-02-12 10:40:29 -06:00
Chris Veilleux
03414990bc
applied schema changes
2019-02-12 10:39:58 -06:00
Chris Veilleux
7936bed82f
added ability to decorate functions that return values
2019-02-12 10:39:05 -06:00
Chris Veilleux
71497b6549
changed update and delete methods to return the number of affected rows
2019-02-12 10:38:16 -06:00
Chris Veilleux
5f548d8aa0
minor refactor
2019-02-12 10:37:46 -06:00
Chris Veilleux
dcaf17b5f3
added new validator-collection package and used it to validate the email address on the account object.
2019-02-08 16:25:12 -06:00
Chris Veilleux
75d576f84d
define a decorator for executing all sql within a class method in a transaction. commits will occur on success, rollbacks on failure.
2019-02-08 16:12:12 -06:00
Chris Veilleux
65d19a147d
ensure all add account insert statements occur within a transaction
2019-02-08 15:15:28 -06:00
Chris Veilleux
44cf4e9e6f
added tests of the account endpoint returning subscription and agreement data
2019-02-07 22:41:12 -06:00
Chris Veilleux
0afedc89c3
added start date to the subscription data
2019-02-07 21:01:30 -06:00
Chris Veilleux
ca2fa5a78b
put account endpoint in api library because all api's that interact with web apps will need it
2019-02-07 20:03:41 -06:00
Chris Veilleux
02a3db7c0f
moved token generation test code to api library for re-use
2019-02-07 20:02:43 -06:00
Chris Veilleux
6f229d8977
minor merge conflict
2019-02-07 19:52:47 -06:00
Chris Veilleux
7db6557af2
changed selene.util.encoder to no longer need a custom JSON encoder and moved into the selene.api package
2019-02-07 19:42:42 -06:00
Matheus Lima
a3a7537d2a
fixing typo
2019-02-07 18:09:34 -03:00
Matheus Lima
ba213a8486
Changes to use relative imports
2019-02-07 18:05:07 -03:00
Matheus Lima
492d298a1e
Using relative imports to define package level APIs
2019-02-07 17:48:39 -03:00
Matheus Lima
edaba3c812
Fixes related to previous refactoring
2019-02-07 17:34:47 -03:00
Matheus Lima
e38274e92a
Fixes related to previous refactoring
2019-02-07 17:12:21 -03:00
Chris Veilleux
0b28b18b39
moved all data access layer code into a new selene.data package
2019-02-07 13:14:40 -06:00
Chris Veilleux
ae9d0dc3a7
fixed merge conflicts
2019-02-07 12:49:20 -06:00
Chris Veilleux
c698bb9e05
added docstrings
2019-02-07 12:19:25 -06:00
Matheus Lima
022e2780f9
- Adding comments to the code
...
- Fixing small issue with the get_setting_by_device_id query
2019-02-07 15:13:56 -03:00
Matheus Lima
676eb3f158
- Created endpoint to fetch the subscription type using the device id
2019-02-07 12:35:46 -03:00
Chris Veilleux
10f9e03b20
added more account-related attributes
2019-02-06 22:49:45 -06:00
Chris Veilleux
b964274a44
updated to reflect changes in database access utilities
2019-02-06 22:49:21 -06:00
Chris Veilleux
2e53130ab5
enhanced account object to include other account related data. side-effect was to abstract out some of the get account logic that was redundant
2019-02-06 22:48:46 -06:00
Chris Veilleux
5f7974520f
changed to allow for sql to be changed before passing to db utility functions
2019-02-06 22:45:42 -06:00
Matheus Lima
768a692fb8
- Refactored endpoint `device/{uuid}/skill` to fetch all skills using a single query
...
- Created endpoint to fetch a skill using device id and version_hash
- Removing useless sql files
2019-02-06 21:51:00 -03:00
Chris Veilleux
0fa89ef644
added pyhamcrest package for common api testing package
2019-02-06 13:40:52 -06:00
Chris Veilleux
b9d4a5247e
added ability to execute an "insert returning" SQL statement, which is useful to return values containing a default (like row IDs)
2019-02-06 13:40:15 -06:00
Chris Veilleux
bea58504d6
minor bug
2019-02-06 13:30:53 -06:00
Chris Veilleux
849d65bc21
minor bug fixes
2019-02-06 13:30:33 -06:00
Chris Veilleux
977dc99570
added package for common API testing logic
2019-02-06 13:29:58 -06:00
Chris Veilleux
b963857160
fixed ambiguous where clause error.
2019-02-06 11:06:02 -06:00
Chris Veilleux
ada2f24b5e
fixed a bug with result of add account and added remove account logic
2019-02-05 17:36:24 -06:00
Chris Veilleux
7619e35333
fixed a bug where query wasn't returning account
2019-02-05 17:35:25 -06:00
Chris Veilleux
f5d2f464ed
get rid of the raise of the API error when authentication fails. there is already an indicator of failed authentication, the self.authenticated flag
2019-02-05 16:24:38 -06:00
Chris Veilleux
c9d167549c
added functionality to insert a new account and added the password field back into the account object
2019-02-05 16:23:41 -06:00
Chris Veilleux
745f7fd7e3
added ability to expire a token cookie
2019-02-05 13:25:22 -06:00
Chris Veilleux
845dd6b308
fixed minor bugs found in testing
2019-02-05 12:48:48 -06:00
Chris Veilleux
440bdaabc6
provided ability to specify value of database connection's autocommit attribute
2019-02-05 12:28:49 -06:00
Chris Veilleux
f8f3cf3957
changed join on refresh token table to outer join in case there are no refresh tokens for an account
2019-02-05 12:06:49 -06:00
Chris Veilleux
41cbf732f1
changed join on refresh token table to outer join in case there are no refresh tokens for an account
2019-02-05 12:06:19 -06:00
Chris Veilleux
e4a165d279
new functionality for federated login to ensure the email address exists on our platform
2019-02-05 11:30:37 -06:00
Chris Veilleux
ce444f3293
changed dev domain setting for https purposes
2019-02-05 11:29:35 -06:00
Chris Veilleux
06fbbae76d
changed how cookies are build to fix issue with accessing them in client code
2019-02-05 11:29:00 -06:00
Matheus Lima
8a5476f28b
Improving the function that fetches the device settings by device id to work using a single query. Removing unnecessary functions and sql files after performing this change.
2019-02-05 12:42:01 -03:00
Matheus Lima
0b01fdbe97
- Fixing query to reduce the amount of processing on the code side
2019-02-05 11:09:23 -03:00
Matheus Lima
3f988221f3
- Moving WakeWord and TextToSpeech to own packages
...
- Making the get_device_by_id fetch all entities using a single query
2019-02-04 20:54:15 -03:00
Chris Veilleux
aea9851116
moved the hook to add the cookies to the response into the base class to avoid re-coding it in every place it is needed.
2019-02-04 15:04:22 -06:00
Chris Veilleux
70ccab71de
minor bug fix for cookie domain
2019-02-04 15:03:19 -06:00
Matheus Lima
ade99800ef
- Fixing setup.py to properly include the data files described by MANIFEST.in
...
- Initializing the API config
- Fixing the endpoints to use the config variable to access the connection pool
2019-02-02 22:39:00 -03:00
Matheus Lima
9f29aa5a86
Moving custom encoder logic to the util package in the shared project
2019-02-02 20:36:53 -03:00
Chris Veilleux
604fd6108b
added group by and changed a join to a left join to fix bugs
2019-02-02 00:45:35 -06:00
Chris Veilleux
aec1f18ad8
minor bug fix
2019-02-02 00:45:00 -06:00
Chris Veilleux
4fbe6e1c6d
removed print statement
2019-02-02 00:44:37 -06:00
Chris Veilleux
0e79c40f99
reflect changes to account package
2019-02-01 22:09:30 -06:00
Chris Veilleux
ad0d4820f0
added logic to add a refresh token on sign in; moved refresh token functions in the account repository to their own repository; moved authentication repo into account repo
2019-02-01 22:08:59 -06:00
Chris Veilleux
901a256d54
broke refresh tokens into their own table and added functionality to update/delete a refresh token
2019-02-01 21:41:32 -06:00
Chris Veilleux
c17dcf0a4e
added ability to delete an expired refresh token and update a refresh token
2019-02-01 21:40:44 -06:00
Matheus Lima
b6440abd38
Moving setting folder content into device folder in the shared project
2019-02-01 20:34:59 -03:00
Matheus Lima
f5bbaa0892
Creating endpoints to fetch device, device's setting and device's skills
2019-02-01 20:34:59 -03:00
Chris Veilleux
0df1211409
Merge remote-tracking branch 'remotes/origin/tartarus-overhaul' into single-sign-on-api
2019-02-01 15:16:41 -06:00
Chris Veilleux
45a9115c66
removed unnecessary quotation marks
2019-02-01 15:14:23 -06:00
Chris Veilleux
cde0db0f3f
Merge remote-tracking branch 'remotes/origin/tartarus-overhaul' into single-sign-on-api
2019-02-01 14:23:39 -06:00
Chris Veilleux
9f0fe936d7
added psycopg2 to dependencies
2019-02-01 14:23:18 -06:00
Chris Veilleux
a23fa4dec3
Merge remote-tracking branch 'remotes/origin/tartarus-overhaul' into single-sign-on-api
2019-02-01 14:05:06 -06:00
Chris Veilleux
585f9332db
Fixed how the packages were identified
2019-02-01 14:03:59 -06:00
Chris Veilleux
a04a710f9a
merging in tartarus-overhaul
2019-02-01 13:52:14 -06:00
Chris Veilleux
f78db57883
Create __init__.py
2019-02-01 13:49:42 -06:00
Chris Veilleux
dc9dce74d2
changed package name in to selene
2019-02-01 13:49:01 -06:00
Chris Veilleux
33cfe4c63b
minor refactor
2019-02-01 00:43:59 -06:00
Chris Veilleux
1085c6ead7
new sql for updating the refresh token
2019-02-01 00:33:49 -06:00
Chris Veilleux
b733f68d7f
new repository for authentication logic
2019-02-01 00:32:52 -06:00
Chris Veilleux
753c522833
added imports
2019-02-01 00:32:29 -06:00
Chris Veilleux
f458e809e9
added refresh token logic
2019-02-01 00:32:09 -06:00
Chris Veilleux
e4a21a25e9
updated to return all columns
2019-02-01 00:26:28 -06:00
Chris Veilleux
2dcb851382
added refresh token to query and refactored
2019-02-01 00:26:03 -06:00
Chris Veilleux
9bd0622fc2
added refresh token to dataclass
2019-02-01 00:25:27 -06:00
Chris Veilleux
51e706dce6
converted function into repository class and added method to update the refresh token
2019-02-01 00:24:34 -06:00
Chris Veilleux
1c6e53d3af
added domains for cookies
2019-02-01 00:23:37 -06:00
Chris Veilleux
fa94d5b1df
added refresh token logic
2019-02-01 00:23:03 -06:00
Chris Veilleux
4554cbdd0b
updated by pipenv
2019-02-01 00:22:05 -06:00
Chris Veilleux
cc8f0fb81e
updated name of repository
2019-02-01 00:21:44 -06:00
Chris Veilleux
a7e091b7fe
enhanced and refactored to add crud abilities
2019-02-01 00:17:04 -06:00
Chris Veilleux
35a9dcba1b
enhanced and refactored to add crud abilities
2019-02-01 00:16:53 -06:00
Chris Veilleux
81f090b2d1
Merge pull request #37 from MycroftAI/logging-setup
...
Logging setup
2019-01-31 13:06:20 -06:00
Chris Veilleux
b64949173e
down-merge from tartararus-overhaul
2019-01-31 11:25:07 -06:00
Chris Veilleux
69fcd2f65f
merging tartarus-overhaul onto branch
2019-01-31 11:17:47 -06:00
Chris Veilleux
c0ed35a9f6
added some comments to clarify the different connection methods.
2019-01-31 11:13:44 -06:00
Chris Veilleux
0731c3e449
initial attempt at standardizing logging functionality across the selene backend
2019-01-31 11:06:27 -06:00
Chris Veilleux
6604c8d355
new function to validate user credentials against the database
2019-01-30 23:23:22 -06:00
Chris Veilleux
a47c67798a
fixed some docstring typos and added an ENV value
2019-01-30 23:14:35 -06:00
Chris Veilleux
c54590895c
abstract global config setup
2019-01-30 22:25:02 -06:00
Chris Veilleux
48e3509277
add package api to __init__.py
2019-01-30 22:24:14 -06:00
Chris Veilleux
2bd45ae7e1
merge connection_pooling onto abstract-api-common
2019-01-30 21:59:28 -06:00
Chris Veilleux
934ad323eb
removed lingering package from recent git acrobatics
2019-01-30 20:39:48 -06:00
Chris Veilleux
01f17d03de
fixed a couple of minor bugs encountered in testing
2019-01-30 20:32:20 -06:00
Chris Veilleux
4cf170592d
moved common API logic from selene.util to new selene.api package. the util package is for non-business logic and the common api bits contain business logic
2019-01-30 19:16:46 -06:00
Chris Veilleux
cd3b67b127
initial attempt at implementing database connection pooling. side effect of changes was converting selene.util.db to a package to split out the different database functions in to their own modules
2019-01-30 18:57:31 -06:00
Chris Veilleux
d1d0189ec3
moved device.py into the right place
2019-01-30 18:37:12 -06:00
Chris Veilleux
a197529e9b
new approach to storing data classes and data access logic.
2019-01-30 14:54:19 -06:00
Chris Veilleux
d168d25717
reorganized the shared directory to have a top-level "selene" package that all other shared packages will be included in.
2019-01-30 14:49:54 -06:00
Chris Veilleux
f199e0969b
moved the contents of the "backend" directory up one level since this repo is now just for backend code
2019-01-30 14:47:18 -06:00
Chris Veilleux
2810b60fa6
moved backend code to new directory structure
2018-11-02 14:47:13 -05:00
Chris Veilleux
f5b24ddf68
minor PEP8 refactor
2018-10-11 15:10:28 -05:00
Chris Veilleux
5122dc96d0
moved JWT creation logic to shared package for re-usability
2018-09-26 22:36:44 -05:00
Chris Veilleux
2cb8bf3083
the config attribute of the base class cannot be set until instantiation time.
2018-09-26 22:02:23 -05:00
Chris Veilleux
eebdf7edf4
minor refactor
2018-09-26 21:58:21 -05:00
Chris Veilleux
f299988d21
renamed base class again... i just can't seem to make up my mind!
2018-09-26 16:23:10 -05:00
Chris Veilleux
7c8c7d9f7f
renamed the base class to more closely represent the resource object it inherits from
2018-09-26 16:21:47 -05:00
Chris Veilleux
fb34f3025e
remove the default methods representing the different HTTP verbs. Flask takes care of raising 405 errors, no reason to replicate the logic
2018-09-26 16:19:58 -05:00
Chris Veilleux
3b8fda347c
refactored
2018-09-25 22:20:00 -05:00
Chris Veilleux
eb2c392f01
changed the exception name AuthenticationError instead of AuthorizationError since this method we are authenticating, not authorizing
2018-09-25 22:15:50 -05:00
Chris Veilleux
7e67073307
added an *args argument to the get method in case arguments are passed in subclasses
2018-09-22 16:44:19 -05:00
Chris Veilleux
722b893c45
refactored response logic and added 405 errors for unsupported methods
2018-09-20 17:17:19 -05:00
Chris Veilleux
16f1cd0286
split the login out from the repository access.
2018-09-12 23:00:42 -05:00
Chris Veilleux
0306638f5f
not sure why this changed, but it did
2018-08-24 17:26:47 -05:00
Chris Veilleux
d666645662
added missing required packages
2018-08-22 23:24:40 -05:00
Chris Veilleux
895a7e66b1
added the flask-restful package
2018-08-22 23:22:19 -05:00
Chris Veilleux
dc36d12d61
Parend Dockerfile for Selene services and APIs
2018-08-22 22:10:43 -05:00
Chris Veilleux
6930166924
Pipfiles to support pipenv
2018-08-22 22:09:58 -05:00
Chris Veilleux
a6ff57d891
added setup.py file so that pipenv could install to other local packages
2018-08-22 22:09:28 -05:00
Chris Veilleux
7f87c6a7c0
new selene_util package
2018-08-22 22:05:54 -05:00
Chris Veilleux
250f4b8f6f
moved the endpoints into a sub-package to debug an error with uwsgi
2018-08-21 16:18:56 -05:00