Skip to content
Myr

quicker start

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Kenneth Reitz · committed by Kenneth Reitz · parent 40c5480 · Browse files · 1 file+2 added−4 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+2 added−4 removed

  • other:+2 added−4 removed

1 file+2 added−4 removed

modified:docs/user/quickstart.rst+2 added-4 removed
130 unmodified lines
131 }132133134135136135Response Status Codes136---------------------137138We can check the response status code::
89 unmodified lines
228Basic Authentication229--------------------230231Most web services require authentication. There many different types of234authentication, but the most common is called HTTP Basic Auth.232authentication, but the most common is HTTP Basic Auth.233234Making requests with Basic Auth is extremely simple::235236 >>> requests.get('https://api.github.com/user', auth=('user', 'pass'))
2 unmodified lines
239240Digest Authentication241---------------------242245Another popular form of protecting web service is Digest Authentication::243Another popular form of web service protection is Digest Authentication::244245 >>> url = 'http://httpbin.org/digest-auth/auth/user/pass'246 >>> requests.get(url, auth=('digest', 'user', 'pass'))247 <Response [200]>
5 unmodified lines