Skip to content

Commit

Permalink
feat: add code as comment lines for basic authentication (#116)
Browse files Browse the repository at this point in the history
  • Loading branch information
ozgurkaraaslan committed Jun 21, 2024
1 parent 49f85c9 commit 36e87bf
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 1 deletion.
3 changes: 2 additions & 1 deletion examples/http/get.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,10 @@
picoLTE.network.register_network()
picoLTE.http.set_context_id()
picoLTE.network.get_pdp_ready()
# Uncomment the line below if you use basic HTTP authentication with username and password given in config.json file.
# picoLTE.http.set_auth()
picoLTE.http.set_server_url()


debug.info("Sending a GET request.")

result = picoLTE.http.get()
Expand Down
2 changes: 2 additions & 0 deletions examples/http/get_with_custom_header.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
picoLTE.network.register_network()
picoLTE.http.set_context_id()
picoLTE.network.get_pdp_ready()
# Uncomment the line below if you use basic HTTP authentication with username and password given in config.json file.
# picoLTE.http.set_auth()
picoLTE.http.set_server_url()

# Get URL from the config.json.
Expand Down
2 changes: 2 additions & 0 deletions examples/http/post.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
picoLTE.network.register_network()
picoLTE.http.set_context_id()
picoLTE.network.get_pdp_ready()
# Uncomment the line below if you use basic HTTP authentication with username and password given in config.json file.
# picoLTE.http.set_auth()
picoLTE.http.set_server_url()

debug.info("Sending a POST request.")
Expand Down
2 changes: 2 additions & 0 deletions examples/http/post_with_custom_header.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
picoLTE.network.register_network()
picoLTE.http.set_context_id()
picoLTE.network.get_pdp_ready()
# Uncomment the line below if you use basic HTTP authentication with username and password given in config.json file.
# picoLTE.http.set_auth()
picoLTE.http.set_server_url()

# Get URL from the config.json.
Expand Down
2 changes: 2 additions & 0 deletions examples/http/put.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
picoLTE.network.register_network()
picoLTE.http.set_context_id()
picoLTE.network.get_pdp_ready()
# Uncomment the line below if you use basic HTTP authentication with username and password given in config.json file.
# picoLTE.http.set_auth()
picoLTE.http.set_server_url()

debug.info("Sending a PUT request.")
Expand Down

0 comments on commit 36e87bf

Please sign in to comment.