Session Token Works with Postman but not with Python Requests

In Progress

Comments

3 comments

  • Avatar
    Andrey Terentyev

    Hello,

    These redirects in pythons should be processed slightly different than just setting allow_redirects=True.

    Please see a code example in our repo on GitHub

    https://github.com/networkoptix/nx_open_integrations/blob/master/python/examples/common/server_api.py

    0
    Comment actions Permalink
  • Avatar
    Aashish Dhakal

    Thanks for your quick reply, I tried that already. That's the case when you receive temporary redirect status codes in the response. This is not the case, the requests throw 401 directly, which doesn't even enter the redirect handling condition. 

    0
    Comment actions Permalink
  • Avatar
    Andrey Terentyev

    Hi,

    HTTP error 401 means Unauthorized. Please, check that credentials you're using in your python script are valid and the authentication scheme you're using in python script is the same set for the account in VMS.

    0
    Comment actions Permalink

Please sign in to leave a comment.