Giter Site home page Giter Site logo

dribia / drifactorial Goto Github PK

View Code? Open in Web Editor NEW
7.0 2.0 0.0 692 KB

Python client for the Factorial API.

Home Page: https://dribia.github.io/drifactorial/

License: MIT License

Python 97.32% Shell 2.68%
python api-client hr hr-software human-resources

drifactorial's Issues

Unable to authorize

Expected Behavior

To push the Authorization Code via the obtain_access_token function and receive the access_token.

Current Behavior

Currently I am receiving the authorization code, but unable to get the access_token

Possible Solution

Steps to Reproduce

  1. Open new project -> pip install drifactorial
  2. Following the guide: https://dribia.github.io/drifactorial/usage/authorization/
  3. Up tot "Authorize your user for using the application" goes well
  4. When I enter:
    token = dummy_factorial.obtain_access_token( client_id=client_id, client_secret=client_secret, redirect_uri=redirect_uri, authorization_key=authorization_key, )

I recieve the following errors:
>>> token = dummy_factorial.obtain_access_token( ... client_id=client_id, ... client_secret=client_secret, ... redirect_uri=redirect_uri, ... authorization_key=authorization_key, ... ) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "C:\Users\CND127KONB\PycharmProjects\pythonProject\venv\lib\site-packages\drifactorial\__init__.py", line 379, in obtain_access_token response = self._post_token(data=data) File "C:\Users\CND127KONB\PycharmProjects\pythonProject\venv\lib\site-packages\drifactorial\__init__.py", line 360, in _post_token response = request.urlopen(request_url) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1520.0_x64__qbz5n2kfra8p0\lib\urllib\request.py", line 216, in urlopen return opener.open(url, data, timeout) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1520.0_x64__qbz5n2kfra8p0\lib\urllib\request.py", line 525, in open response = meth(req, response) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1520.0_x64__qbz5n2kfra8p0\lib\urllib\request.py", line 634, in http_response response = self.parent.error( File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1520.0_x64__qbz5n2kfra8p0\lib\urllib\request.py", line 563, in error return self._call_chain(*args) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1520.0_x64__qbz5n2kfra8p0\lib\urllib\request.py", line 496, in _call_chain result = func(*args) File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1520.0_x64__qbz5n2kfra8p0\lib\urllib\request.py", line 643, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError: HTTP Error 400: Bad Request

  1. I have tried putting in the client_id, client_secret, redirect_uri and authorization_key manually by hand, so to make sure they match..
  2. Looking into the drifactorial -> init.py file, hovering over the variables named at step 1, they do not visualize the variable values..

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.