khttp Documentation Release jkcclemens
|
|
- Sybil Burns
- 5 years ago
- Views:
Transcription
1 khttp Documentation Release jkcclemens May 12, 2017
2
3 Contents 1 Feature support 3 2 User guide Installation khttp s differences Quickstart Advanced usage i
4 ii
5 khttp is a Mozilla Public License 2.0 licensed library, written in Kotlin, inspired by requests, for human beings. Java is bad at HTTP. Really bad. The tools provided are functionally broken. Unfortunately, by extension, Kotlin is also bad at HTTP. Yet, more and more, the need to interact with APIs and perform basic HTTP requests shows up in programs, but the broken tools in Java make it a big fuss. This isn t how it should be. To combat this, libraries like Unirest have popped up, but they introduce massive amounts of overhead to just make a simple GET request. khttp attempts to solve this problem, by mimicking the Python requests module. khttp uses only the org.json. json library and native Java. There s nothing else. No bullshit. val r = get(" auth=basicauthorization("user", "pass")) r.statuscode // 200 r.headers["content-type"] // "application/json; charset=utf-8" r.text // """{"type": "User"...""" r.jsonobject // org.json.jsonobject See similar code, without khttp. Contents 1
6 2 Contents
7 CHAPTER 1 Feature support khttp is ready for today s web. International domains and URLs Sessions with cookie persistence Basic authentication Elegant key/value cookies Automatic decompression Unicode response bodies Connection timeouts 3
8 4 Chapter 1. Feature support
9 CHAPTER 2 User guide Installation khttp is a new library, and it isn t on Maven Central, yet. Once it matures a bit, it will be looked into. JitPack JitPack is a great service that will build GitHub projects and offer them as a repository for free. If you want to use khttp in a project, use JitPack. Maven Add the JitPack repository <repository> <id>jitpack.io</id> <url> </repository> Add the dependency <dependency> <groupid>com.github.jkcclemens</groupid> <artifactid>khttp</artifactid> <version>-snapshot</version> </dependency> As khttp has no official releases or tags at the moment, JitPack uses -SNAPSHOT to denote the latest commit. 5
10 Get the code khttp is actively developed on GitHub, where the code is always available. You can either clone the public repository: $ git clone git://github.com/jkcclemens/khttp.git Download the tarball: $ curl -OL Or, download the zipball: $ curl -OL khttp s differences While khttp may be made in requests image, it is different in many ways. This part of the documentation explores some important ways in which it is different. It also touches on the differences in how HTTP requests are handled on a lower level. Notable variations from requests khttp attempts to be as close to the requests module as possible, but there are some variations, especially in features that have yet to be implemented. Some parameters are missing The missing parameters from request methods are proxies, verify, and cert. These are planned for implementation. The json() function is split into two properties: jsonobject and jsonarray There is no unifying JSON interface that both JSONObject and JSONArray implement. Rather than creating a wrapper that requires casting and type-checking, there are simply two properties instead of one function. Notable variations from plain ol Java These are variations in how HTTP requests are handled. Obviously the methods in which the requests are made are very, very different. HTTP status codes indicative of errors don t throw exceptions HttpURLConnections really don t like it when there are bad status codes. If you try to get the InputStream of any request that has an error status code, an exception will be thrown, making it so the content can t even be seen. khttp rectifies this. Go ahead, try println(get(" for a pretty picture of a teapot. Of course, if you were using these exceptions to check for errors, now just check the statuscode property. Cookies persist across redirects Java really, really doesn t handle cookies well. Cookies aren t even handled unless a global manager for all requests is set. That s dumb. 6 Chapter 2. User guide
11 khttp allows for the setting and retrieving of cookies, and they persist through redirects, if redirects are allowed. If a POST request is made to a login form, and a cookie is set before being redirected back to the homepage, that cookie will be available in the homepage response. All HTTP methods are allowed, even ones that don t exist Plain ol Java limits requests to the HTTP methods that existed at the time of the creation of the HTTP classes. This means that some HTTP methods like PATCH aren t allowed. khttp overrides this, allowing any method to be used. Quickstart Ready to get started with a better way to make requests? This part of the documentation aims to get you up and running in no time. Let s start with some simple examples, analogous to the ones found in requests quickstart guide. Make a request Making a request with khttp is very simple. Start by importing the request method for the type of request you want to make. For this example, we ll be using GET, so let s import that. import khttp.get Now, let s try to get a webpage. For example, let s get GitHub s public timeline. val r = get(" Now, we have a Response object called r. We can get all the information we need from this object. khttp s API is straightforward, so all forms of HTTP requests are pretty obvious. For example, here s a quick POST request. import khttp.post post(" data = mapof("key" to "value")) Easy. khttp supports every other HTTP request, as well. import khttp.* var r = put(" data = mapof("key" to "value")) r = delete(" r = head(" r = options(" If, for some reason, you need a nonstandard request type, that s supported too. import khttp.request val r = request("nonstandard", " Note: From here on out, the import statements are going to be dropped from the code snippets. They should all be easy enough to figure out Quickstart 7
12 Passing parameters in URLs You often want to send some sort of data in the URL s query string. If you were constructing the URL by hand, this data would be given as key/value pairs in the URL after a question mark, e.g. httpbin.org/get?key=val. khttp allows you to provide these arguments as an object, using the params argument. As an example, if you wanted to pass key1=value1 and key2=value2 to httpbin.org/get, you would use the following code: val payload = mapof("key1" to "value1", "key2" to "value2") val r = get(" params=payload) Note that there is a Parameters class that can be used, as well. There s no real advantage to using it, but it is an option. Note that FormParameters is used for data, not URL parameters (although it will still work as URL parameters if given to the params argument). You can see that the URL has been correctly encoded by printing the URL. Note: At the moment, only Strings can be passed as parameters. In the future, Any will be allowed, which will enable Collections to be passed. println(r.url) // Response content We can read the content of the server s response. Consider the GitHub timeline again: val r = get(" println(r.text) // [{"repository":{"open_issues":0,"url":" When you make a request, khttp makes educated guesses about the encoding of the response based on the HTTP headers. The text encoding guessed by khttp is used when you access r.text. You can find out what encoding khttp is using, and change it, using the r.encoding property: println(r.encoding) // UTF-8 r.encoding = Charsets.ISO_8859_1 If you change the encoding, khttp will use the new value of r.encoding whenever you call r.text. You might want to do this in any situation where you can apply special logic to work out what the encoding of the content will be. For example, HTTP and XML have the ability to specify their encoding in their body. In situations like this, you should use r.raw to find the encoding, and then set r.encoding. This will let you use r.text with the correct encoding. Binary response content You can also access the response body as a ByteArray, for non-text requests: r.content // ByteArray The gzip and deflate transfer-encodings are automatically decoded for you. 8 Chapter 2. User guide
13 JSON response content In case you re dealing with JSON data, khttp will use org.json.json to provide two properties: jsonobject and jsonarray. val r = get(" println(r.jsonarray) // [{"actor":{"avatar_url":" Note that if you attempt to access jsonobject but the content is an array, an exception will be thrown and vice versa. If the content is not JSON, an exception will also be thrown. It should be noted that the success of calls to these properties does not indicate the success of the response. Some servers may return a JSON object in a failed response (e.g. error details with HTTP 500). Such JSON will be decoded and returned. To check that a request is successful, check that r.statuscode is what you expect. Raw response content In the rare case that you d like to get the raw InputStream response from the server, you can access r.raw. If you want to do this, make sure you set stream to true in your initial request. Once you do, you can do this: val r = get(" stream=true) r.raw // InputStream r.raw.read() // 91 In general, however, you should use a pattern like this to save what is being streamed to a file: for (chunk in r.contentiterator(chunksize)) { file.appendbytes(chunk) } When streaming a download, the above is the preferred and recommended way to retrieve the content. Custom headers If you d like to add HTTP headers to a request, simply pass in a Map to the headers parameter. For example, accessing a super secret API: val r = get(" headers=mapof("x-api-key" to "secret")) Some headers may be overwritten depending on context. For example, if the json argument is specified, the Content- Type header will be forced to application/json. khttp does not change behavior based on any specified request headers. It does change behavior based on response headers. More complicated POST requests Typically, you want to send some form-encoded data much like an HTML form. To do this, simply pass a Map to the data argument. Your Map of data will automatically be form-encoded when the request is made: 2.3. Quickstart 9
14 val payload = mapof("key1" to "value1", "key2" to "value2") val r = post(" data=payload) println(r.text) /* {... "form": { "key1": "value1", "key2": "value2" },... } */ There are many times that you want to send data that is not form-encoded. If you pass in any object except for a Map, that data will be posted directly (via the tostring() method). For example, the GitHub API v3 accepts JSON-Encoded POST/PATCH data: val url = " val payload = mapof("some" to "data") val r = post(url, data=jsonobject(payload)) Instead of encoding the JSON yourself, you can also pass it directly using the json parameter, and it will be encoded automatically: val url = " val payload = mapof("some" to "data") r = post(url, json=payload) POST a multipart-encoded file khttp makes it simple to upload multipart-encoded files: val url = " val files = listof(file("report.xls").filelike()) val r = post(url, files = files) r.text /* {... "files": { "report.xls": "<censored...binary...data>" },... } */ You can set the filename explicitly: val url = " val files = listof(file("report.xls").filelike(name = "best_report.xls")) 10 Chapter 2. User guide
15 val r = post(url, files = files) r.text /* {... "files": { "best_report.xls": "<censored...binary...data>" },... } */ If you want, you can send strings to be received as files: val url = " val files = listof("some,data,to,send\nanother,row,to,send\n".filelike(name = "report. csv")) val r = post(url, files = files) r.text /* {... "files": { "report.csv": "some,data,to,send\nanother,row,to,send\n" },... } */ The files parameter is a list of FileLike objects. These objects support all of the methods of uploading files available in requests, but they have a slightly different syntax to be more statically-typed. The filelike(name: String =...) extension function is available on File, Path, and String. This extension function will create FileLike objects in a convenient manner. You can also use the FileLike constructor to create a suitable object. In the event that you are posting a very large file as a multipart/form-data request, you may want to stream the request. By default, khttp does not support this. Response status codes We can check the response status code: val r = get(" r.statuscode // 200 Response headers We can view the server s response headers using a Map: r.headers // {Server=nginx, Access-Control-Allow-Origin=*, Access-Control-Allow- Credentials=true, Connection=keep-alive, Content-Length=235, Date=Wed, 21 Oct :19:06 GMT, Content-Type=application/json} 2.3. Quickstart 11
16 The Map is special, though: it s made just for HTTP headers. According to RFC 7230, HTTP header names are case-insensitive. So, we can access the headers using any capitalization we want: headers["content-type"] // application/json r.headers.get("content-type") // application/json It is also special in that the server could have sent the same header multiple times with different values, but khttp combines them so they can be represented in the Map within a single mapping, as per RFC 7230: A recipient MAY combine multiple header fields with the same field name into one field-name: fieldvalue pair, without changing the semantics of the message, by appending each subsequent field value to the combined field value in order, separated by a comma. Cookies If a response contains some Cookies, you can quickly access them: val url = " val r = get(url) r.cookies["example_cookie_name'] // example_cookie_value Note that khttp will keep cookies persistent throughout redirects. To send your own cookies to the server, you can use the cookies parameter: val url = " val cookies = mapof("cookies_are" to "working") val r = get(url, cookies=cookies) r.text /* { "cookies": { "cookies_are": "working" } } */ Redirection and history By default khttp will perform location redirection for all verbs except for HEAD. If redirect for HEAD requests are desired, you can set the allowredirects parameter in the request to true. We can use the history property of the Response object to track redirection. The history list contains the Response objects that were created in order to complete the request. The list is sorted from the oldest to the most recent response. For example, GitHub redirects all HTTP requests to HTTPS: 12 Chapter 2. User guide
17 val r = get(" r.url // r.statuscode // 200 r.history // [<Response [301]>] If you want to disable redirection handling, you can do so with the allowredirects parameter. val r = get(" allowredirects = false) r.statuscode // 301 r.history // [] Timeouts You can tell khttp to stop waiting for a response after a given number of seconds with the timeout parameter. get(" timeout=0.001) /* java.net.sockettimeoutexception: connect timed out at java.net.plainsocketimpl.socketconnect(native Method) at java.net.abstractplainsocketimpl.doconnect(abstractplainsocketimpl. java:345) at java.net.abstractplainsocketimpl.connecttoaddress(abstractplainsocketimpl. java:206) at java.net.abstractplainsocketimpl.connect(abstractplainsocketimpl.java:188) at java.net.sockssocketimpl.connect(sockssocketimpl.java:392) at java.net.socket.connect(socket.java:589) at sun.net.networkclient.doconnect(networkclient.java:175) at sun.net. at sun.net. at sun.net. at sun.net. at sun.net. at sun.net. getnewhttpclient(httpurlconnection.java:1168) at sun.net. plainconnect0(httpurlconnection.java:1104) at sun.net. java:998) at sun.net. java:932) at khttp.responses.genericresponse.openredirectingconnection(genericresponse. kt:35) at khttp.responses.genericresponse.getconnection(genericresponse.kt:73) at khttp.khttp.request(khttp.kt:53) at khttp.khttp.get(khttp.kt:22) at khttp.khttp.get$default(khttp.kt:21) */ 2.3. Quickstart 13
18 Advanced usage This document covers some of khttp s more advanced features. Streaming uploads khttp supports streaming uploads, which allow you to send large streams or files without reading them into memory. To stream and upload, simply provide a File object for your body: val file = File("massive-body") post(" data = file) Request and response objects Whenever a call is made to khttp.get() and friends you are doing two major things. First, you are constructing a Request object which will be sent off to a server to request or query some resource. Second, a Response object is generated once khttp gets a response back from the server. The Response object contains all of the information returned by the server and also contains the Request object you created originally. Here is a simple request to get some very important information from Wikipedia s servers: val r = khttp.get(" If we want to access the headers the server sent back to us, we do this: r.headers // {X-Cache=cp1053 hit (6), cp1053 frontend hit (229), Server=nginx/1.9.4, X-Content- Type-Options=nosniff, Connection=keep-alive, Last-Modified=Sun, 08 Nov :49:30 GMT, Date=Wed, 11 Nov :53:20 GMT, Via=1.1 varnish, 1.1 varnish, Accept-Ranges=bytes, X-Varnish= , , X-UA- Compatible=IE=Edge, Strict-Transport-Security=max-age= ; includesubdomains; preload, Cache-Control=private, s-maxage=0, max-age=0, must-revalidate, Content- language=en, Content-Encoding=gzip, Vary=Accept-Encoding,Cookie, Content- Length=69400, X-Analytics=page_id=18942;ns=0;WMF-Last-Access=11-Nov-2015;https=1, Age=237769, X-Powered-By=HHVM/3.6.5, Content-Type=text/html; charset=utf-8} However, if we want to get the headers we sent the server, we simply access the request, and then the request s headers: r.request.headers // {Accept=*/*, Accept-Encoding=gzip, deflate, User-Agent=khttp/1.0.0-SNAPSHOT} Asynchronous Requests An asynchronous request can be performed by prefixing the desired HTTP method with the keyword async. The response information is passed through the onresponse callback parameter which provides a reference to a Response object. On the other hand, error information is passed through the onerror callback parameter which provides a reference to a Throwable object. The default onresponse callback simply consumes the Response object while the default onerror callback throws the Throwable object. Usage without specifying an onerror callback is as follows: khttp.async.get(" onresponse = { println("status Code: $statuscode") println("response Text: $text") 14 Chapter 2. User guide
19 }) // OR... khttp.async.get(" { println("status Code: $statuscode") println("response Text: $text") } The onerror callback can be included as follows: khttp.async.get(" onerror = { println("error message: $message") }, onresponse = { println("status Code: $statuscode") println("response Text: $text") }) // OR... khttp.async.get(" onerror = { println("error message: $message") }) { println("status Code: $statuscode") println("response Text: $text") } 2.4. Advanced usage 15
Requests Mock Documentation
Requests Mock Documentation Release 1.5.1.dev4 Jamie Lennox Jun 16, 2018 Contents 1 Overview 3 2 Using the Mocker 5 2.1 Activation................................................ 5 2.2 Class Decorator.............................................
More informationREST Web Services Objektumorientált szoftvertervezés Object-oriented software design
REST Web Services Objektumorientált szoftvertervezés Object-oriented software design Dr. Balázs Simon BME, IIT Outline HTTP REST REST principles Criticism of REST CRUD operations with REST RPC operations
More informationGuzzle: Extraordinary HTTP Client
Guzzle: Extraordinary HTTP Client Rob Allen @akrabat ~ akrabat.com ~ September 2016 Why HTTP clients in PHP? Talking to web services Authentication with 3rd parties Social media interaction Remote APIs
More informationurllib3 Documentation
urllib3 Documentation Release 1.3 Andrey Petrov July 22, 2012 CONTENTS i ii CHAPTER ONE CONNECTIONPOOLS A connection pool is a container for a collection of connections to a specific host. If you need
More informationGuzzle: Extraordinary HTTP Client
Guzzle: Extraordinary HTTP Client Rob Allen @akrabat ~ akrabat.com ~ September 2016 Why HTTP clients in PHP? Talking to web services Authentication with 3rd parties Social media interaction Remote APIs
More informationREST. Lecture BigData Analytics. Julian M. Kunkel. University of Hamburg / German Climate Computing Center (DKRZ)
REST Lecture BigData Analytics Julian M. Kunkel julian.kunkel@googlemail.com University of Hamburg / German Climate Computing Center (DKRZ) 11-12-2015 Outline 1 REST APIs 2 Julian M. Kunkel Lecture BigData
More informationFlask Slither Documentation
Flask Slither Documentation Release 0.3 Nico Gevers Sep 27, 2017 Contents 1 Getting Started with Slither 3 1.1 Installation................................................ 3 1.2 Creating the App.............................................
More informationdjangotribune Documentation
djangotribune Documentation Release 0.7.9 David THENON Nov 05, 2017 Contents 1 Features 3 2 Links 5 2.1 Contents................................................. 5 2.1.1 Install..............................................
More informationFlask-Cors Documentation
Flask-Cors Documentation Release 3.0.4 Cory Dolphin Apr 26, 2018 Contents 1 Installation 3 2 Usage 5 2.1 Simple Usage............................................... 5 3 Documentation 7 4 Troubleshooting
More information20.5. urllib Open arbitrary resources by URL
1 of 9 01/25/2012 11:19 AM 20.5. urllib Open arbitrary resources by URL Note: The urllib module has been split into parts and renamed in Python 3.0 to urllib.request, urllib.parse, and urllib.error. The
More informationPrivacy and Security in Online Social Networks Department of Computer Science and Engineering Indian Institute of Technology, Madras
Privacy and Security in Online Social Networks Department of Computer Science and Engineering Indian Institute of Technology, Madras Lecture 12 Tutorial 3 Part 1 Twitter API In this tutorial, we will learn
More informationGuzzle Release Jun 02, 2017
Guzzle Release Jun 02, 2017 Contents 1 User guide 3 1.1 Overview................................................. 3 1.2 Quickstart................................................ 5 1.3 Clients..................................................
More informationConnexion Documentation
Connexion Documentation Release 0.5 Zalando SE Nov 16, 2017 Contents 1 Quickstart 3 1.1 Prerequisites............................................... 3 1.2 Installing It................................................
More informationOAuth2 Autoconfig. Copyright
Copyright Table of Contents... iii 1. Downloading... 1 1.1. Source... 1 1.2. Maven... 1 1.3. Gradle... 2 2. Authorization Server... 3 3. Resource Server... 4 I. Token Type in User Info... 5 II. Customizing
More informationElevate Web Builder Modules Manual
Table of Contents Elevate Web Builder Modules Manual Table Of Contents Chapter 1 - Getting Started 1 1.1 Creating a Module 1 1.2 Handling Requests 3 1.3 Custom DataSet Modules 8 Chapter 2 - Component Reference
More informationRequests Documentation
Requests Documentation Release 2.1.0 Kenneth Reitz January 15, 2016 Contents 1 Testimonials 3 2 Feature Support 5 3 User Guide 7 3.1 Introduction............................................... 7 3.2 Installation................................................
More informationHTTP (HyperText Transfer Protocol)
1 HTTP (HyperText Transfer Protocol) Table of Contents HTTP (HYPERTEXT TRANSFER PROTOCOL)... 1 HTTP (HYPERTEXT TRANSFER PROTOCOL)... 3 What really happens when you navigate to a URL 3 1. You enter a URL
More informationCSE 333 Lecture HTTP
CSE 333 Lecture 19 -- HTTP Hal Perkins Department of Computer Science & Engineering University of Washington Administrivia Server-side programming exercise due Wed. morning HW4 due a week later - How s
More informationBlack Box DCX3000 / DCX1000 Using the API
Black Box DCX3000 / DCX1000 Using the API updated 2/22/2017 This document will give you a brief overview of how to access the DCX3000 / DCX1000 API and how you can interact with it using an online tool.
More informationRelease Manu Phatak
cache r equestsdocumentation Release 4.0.0 Manu Phatak December 26, 2015 Contents 1 Contents: 1 1.1 cache_requests.............................................. 1 1.2 Installation................................................
More informationdjango-secure Documentation
django-secure Documentation Release 0.1.2 Carl Meyer and contributors January 23, 2016 Contents 1 Quickstart 3 1.1 Dependencies............................................... 3 1.2 Installation................................................
More informationRKN 2015 Application Layer Short Summary
RKN 2015 Application Layer Short Summary HTTP standard version now: 1.1 (former 1.0 HTTP /2.0 in draft form, already used HTTP Requests Headers and body counterpart: answer Safe methods (requests): GET,
More informationscrapekit Documentation
scrapekit Documentation Release 0.1 Friedrich Lindenberg July 06, 2015 Contents 1 Example 3 2 Reporting 5 3 Contents 7 3.1 Installation Guide............................................ 7 3.2 Quickstart................................................
More informationDetects Potential Problems. Customizable Data Columns. Support for International Characters
Home Buy Download Support Company Blog Features Home Features HttpWatch Home Overview Features Compare Editions New in Version 9.x Awards and Reviews Download Pricing Our Customers Who is using it? What
More informationCS 355. Computer Networking. Wei Lu, Ph.D., P.Eng.
CS 355 Computer Networking Wei Lu, Ph.D., P.Eng. Chapter 2: Application Layer Overview: Principles of network applications? Introduction to Wireshark Web and HTTP FTP Electronic Mail SMTP, POP3, IMAP DNS
More informationAutomate Your Workflow Using Tableau Server Client and the REST API
Welcome # T C 1 8 Automate Your Workflow Using Tableau Server Client and the REST API Chris Shin Software Engineer Developer Platform Ang Gao Software Engineer Developer Platform Enabling Integrations
More informationRequests Documentation
Requests Documentation Release 2.2.1 Kenneth Reitz January 15, 2016 Contents 1 Testimonials 3 2 Feature Support 5 3 User Guide 7 3.1 Introduction............................................... 7 3.2 Installation................................................
More informationHow to work with HTTP requests and responses
How a web server processes static web pages Chapter 18 How to work with HTTP requests and responses How a web server processes dynamic web pages Slide 1 Slide 2 The components of a servlet/jsp application
More informationCSE 333 Lecture HTTP
CSE 333 Lecture 19 -- HTTP Hal Perkins Paul G. Allen School of Computer Science & Engineering University of Washington Administrivia HW4 due a week from Thursday - How s it look? Today: http; finish networking/web
More informationCIS192 Python Programming
CIS192 Python Programming HTTP Requests and HTML Parsing Robert Rand University of Pennsylvania March 30, 2016 Robert Rand (University of Pennsylvania) CIS 192 March 30, 2016 1 / 19 Outline 1 HTTP Requests
More informationBazaar Architecture Overview Release 2.8.0dev1
Bazaar Architecture Overview Release 2.8.0dev1 Bazaar Developers November 30, 2018 Contents 1 IDs and keys ii 1.1 IDs..................................................... ii File ids..................................................
More informationFoundations of Python
Foundations of Python Network Programming The comprehensive guide to building network applications with Python Second Edition Brandon Rhodes John Goerzen Apress Contents Contents at a Glance About the
More informationSharePoint 2013 CRUD on List Items Using REST Services & jquery
American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) ISSN (Print) 2313-4410, ISSN (Online) 2313-4402 Global Society of Scientific Research and Researchers http://asrjetsjournal.org/
More informationIntroduction & Basics! Technical Foundation! Authentication! Obtaining a token!... 4 Using the token! Working with notes!...
Simplenote API2 Documentation v2.1.3: (April 18, 2011). Recent documentation changes are listed on the last page. Contents Introduction & Basics!... 3 Technical Foundation!... 3 Authentication!... 4 Obtaining
More informationAim behind client server architecture Characteristics of client and server Types of architectures
QA Automation - API Automation - All in one course Course Summary: In detailed, easy, step by step, real time, practical and well organized Course Not required to have any prior programming knowledge,
More informationspacetrack Documentation
spacetrack Documentation Release 0.13.1 Frazer McLean Feb 03, 2018 Contents 1 Installation 3 1.1 pip.................................................. 3 1.2 Git..................................................
More informationPackage crul. October 3, 2017
Title HTTP Client Package crul October 3, 2017 A simple HTTP client, with tools for making HTTP requests, and mocking HTTP requests. The package is built on R6, and takes inspiration from Ruby's 'faraday'
More informationMarkLogic Server. REST Application Developer s Guide. MarkLogic 9 May, Copyright 2017 MarkLogic Corporation. All rights reserved.
REST Application Developer s Guide 1 MarkLogic 9 May, 2017 Last Revised: 9.0-2, July, 2017 Copyright 2017 MarkLogic Corporation. All rights reserved. Table of Contents Table of Contents REST Application
More informationProgramming for the Web with PHP
Aptech Ltd Version 1.0 Page 1 of 11 Table of Contents Aptech Ltd Version 1.0 Page 2 of 11 Abstraction Anonymous Class Apache Arithmetic Operators Array Array Identifier arsort Function Assignment Operators
More informationComputer Networks. Wenzhong Li. Nanjing University
Computer Networks Wenzhong Li Nanjing University 1 Chapter 8. Internet Applications Internet Applications Overview Domain Name Service (DNS) Electronic Mail File Transfer Protocol (FTP) WWW and HTTP Content
More informationHTTP Requests and Header Settings
Overview, page 1 HTTP Client Requests (HTTP GET), page 1 HTTP Server Requests (HTTP POST), page 2 HTTP Header Settings, page 2 IP Phone Client Capability Identification, page 8 Accept Header, page 9 IP
More informationWeb Programming 4) PHP and the Web
Web Programming 4) PHP and the Web Emmanuel Benoist Fall Term 2013-14 Berner Fachhochschule Haute cole spcialise bernoise Berne University of Applied Sciences 1 PHP a language for Web applications Presentation
More informationAn Introduction to JavaScript & Bootstrap Basic concept used in responsive website development Form Validation Creating templates
PHP Course Contents An Introduction to HTML & CSS Basic Html concept used in website development Creating templates An Introduction to JavaScript & Bootstrap Basic concept used in responsive website development
More informationC24: Web API: Passing Arguments and Parsing Returns
CISC 3120 C24: Web API: Passing Arguments and Parsing Returns Hui Chen Department of Computer & Information Science CUNY Brooklyn College 5/7/2018 CUNY Brooklyn College 1 Outline Parsing arguments/data
More informationPersistence & State. SWE 432, Fall 2016 Design and Implementation of Software for the Web
Persistence & State SWE 432, Fall 2016 Design and Implementation of Software for the Web Today What s state for our web apps? How do we store it, where do we store it, and why there? For further reading:
More informationUnifer Documentation. Release V1.0. Matthew S
Unifer Documentation Release V1.0 Matthew S July 28, 2014 Contents 1 Unifer Tutorial - Notes Web App 3 1.1 Setting up................................................. 3 1.2 Getting the Template...........................................
More informationf5-icontrol-rest Documentation
f5-icontrol-rest Documentation Release 1.3.10 F5 Networks Aug 04, 2018 Contents 1 Overview 1 2 Installation 3 2.1 Using Pip................................................. 3 2.2 GitHub..................................................
More informationGuzzle Release November 14, 2017
Guzzle Release November 14, 2017 Contents 1 User Guide 3 1.1 Overview................................................. 3 1.1.1 Requirements.......................................... 3 1.1.2 Installation...........................................
More informationdjango-mama-cas Documentation
django-mama-cas Documentation Release 2.4.0 Jason Bittel Oct 06, 2018 Contents 1 Contents 3 1.1 Installation................................................ 3 1.2 Settings..................................................
More informationZipRecruiter Apply Webhook Documentation. ZR ATS Integration Team. Version 1.1,
ZipRecruiter Apply Webhook Documentation ZR ATS Integration Team Version 1.1, 2017-10-12 Table of Contents Introduction................................................................................ 1
More informationRESTFUL WEB SERVICES - INTERVIEW QUESTIONS
RESTFUL WEB SERVICES - INTERVIEW QUESTIONS http://www.tutorialspoint.com/restful/restful_interview_questions.htm Copyright tutorialspoint.com Dear readers, these RESTful Web services Interview Questions
More informationINF5750. RESTful Web Services
INF5750 RESTful Web Services Recording Audio from the lecture will be recorded! Will be put online if quality turns out OK Outline REST HTTP RESTful web services HTTP Hypertext Transfer Protocol Application
More informationRelease Presentation. ODS Web Services Version Open Data Services Via Web Services. Release Date: 2014/09/30
Release Presentation ODS Web Services Version 1.1.1 Open Data Services Via Web Services Release Date: 2014/09/30 Deliverables The document represents a companion standard recommendation for interacting
More informationCacheControl Documentation
CacheControl Documentation Release 0.12.4 Eric Larson May 01, 2018 Contents 1 Install 3 2 Quick Start 5 3 Tests 7 4 Disclaimers 9 4.1 Using CacheControl........................................... 9 4.2
More informationGitHub-Flask Documentation
GitHub-Flask Documentation Release 3.2.0 Cenk Altı Jul 01, 2018 Contents 1 Installation 3 2 Configuration 5 3 Authenticating / Authorizing Users 7 4 Invoking Remote Methods 9 5 Full Example 11 6 API Reference
More informationRMNet function calls. Parameters: Usage: Micro Focus. RM/COBOL Development System - RMNET
RMNet function calls All the calls except NetGetError, NetCleanup, and NetFree return a which, when nonzero, the string Free the errorpointer with NetFree. HttpPost This function initiates an HTTP POST
More informationThe HTTP protocol. Fulvio Corno, Dario Bonino. 08/10/09 http 1
The HTTP protocol Fulvio Corno, Dario Bonino 08/10/09 http 1 What is HTTP? HTTP stands for Hypertext Transfer Protocol It is the network protocol used to delivery virtually all data over the WWW: Images
More informationDICOM Correction Proposal
DICOM Correction Proposal STATUS New Date of Last Update 2015/11/09 Person Assigned Jim Philbin (james.philbin@jhmi.edu) Submitter Name Jim Philbin (james.philbin@jhmi.edu) Submission Date 2015/09/13 Correction
More informationIntroduction. Copyright 2018, Itesco AB.
icatch3 API Specification Introduction Quick Start Logging in, getting your templates list, logging out Doing Quick Search Creating a Private Prospects Setting template Posting Private Prospects query,
More informationPhp Manual Header Redirect After 5 Seconds Using
Php Manual Header Redirect After 5 Seconds Using Okay, so I've seen a couple of different approaches for redirecting a user I didn't think it was important but after reading the header manual you are I
More informationWhat is PHP? [1] Figure 1 [1]
PHP What is PHP? [1] PHP is an acronym for "PHP: Hypertext Preprocessor" PHP is a widely-used, open source scripting language PHP scripts are executed on the server PHP is free to download and use Figure
More informationComposer Help. Web Request Common Block
Composer Help Web Request Common Block 7/4/2018 Web Request Common Block Contents 1 Web Request Common Block 1.1 Name Property 1.2 Block Notes Property 1.3 Exceptions Property 1.4 Request Method Property
More informationSTARCOUNTER. Technical Overview
STARCOUNTER Technical Overview Summary 3 Introduction 4 Scope 5 Audience 5 Prerequisite Knowledge 5 Virtual Machine Database Management System 6 Weaver 7 Shared Memory 8 Atomicity 8 Consistency 9 Isolation
More informationflask-jwt-simple Documentation
flask-jwt-simple Documentation Release 0.0.3 vimalloc rlam3 Nov 17, 2018 Contents 1 Installation 3 2 Basic Usage 5 3 Changing JWT Claims 7 4 Changing Default Behaviors 9 5 Configuration Options 11 6 API
More informationOpenProject AdminGuide
OpenProject AdminGuide I. Contents I. Contents... 1 II. List of figures... 2 1 Administration... 2 1.1 Manage projects...2 1.2 Manage users...5 1.3 Manage groups...11 1.4 Manage roles and permissions...13
More informationTable of Contents. Developer Manual...1
Table of Contents Developer Manual...1 API...2 API Overview...2 API Basics: URL, Methods, Return Formats, Authentication...3 API Errors...4 API Response Examples...6 Get Articles in a Category...6 Get
More informationThe Browser Binding with a CMIS Repository
1 The Browser Binding with a CMIS Repository By Florian Müller, Jay Brown, and Jeff Potts, authors of CMIS and Apache Chemistry in Action A big part of the CMIS specification describes how the CMIS domain
More informationflask-jwt Documentation
flask-jwt Documentation Release 0.3.2 Dan Jacob Nov 16, 2017 Contents 1 Links 3 2 Installation 5 3 Quickstart 7 4 Configuration Options 9 5 API 11 6 Changelog 13 6.1 Flask-JWT Changelog..........................................
More informationIntegrating with ClearPass HTTP APIs
Integrating with ClearPass HTTP APIs HTTP based APIs The world of APIs is full concepts that are not immediately obvious to those of us without software development backgrounds and terms like REST, RPC,
More informationManaging State. Chapter 13
Managing State Chapter 13 Textbook to be published by Pearson Ed 2015 in early Pearson 2014 Fundamentals of Web http://www.funwebdev.com Development Section 1 of 8 THE PROBLEM OF STATE IN WEB APPLICATIONS
More informationLecture 7b: HTTP. Feb. 24, Internet and Intranet Protocols and Applications
Internet and Intranet Protocols and Applications Lecture 7b: HTTP Feb. 24, 2004 Arthur Goldberg Computer Science Department New York University artg@cs.nyu.edu WWW - HTTP/1.1 Web s application layer protocol
More informationAPI Knowledge Coding Guide Version 7.2
API Knowledge Coding Guide Version 7.2 You will be presented with documentation blocks extracted from API reference documentation (Javadocs and the like). For each block, you will be also presented with
More informationMixed Signals Using Fusion s Signals API
Mixed Signals Using Fusion s Signals API One of my favorite features in Fusion is the Signals API a RESTful, flexible, easily implemented mechanism for capturing interesting user events, like (but not
More informationUsing OAuth 2.0 to Access ionbiz APIs
Using OAuth 2.0 to Access ionbiz APIs ionbiz APIs use the OAuth 2.0 protocol for authentication and authorization. ionbiz supports common OAuth 2.0 scenarios such as those for web server, installed, and
More informationTOA4 Remote Procedure Call (RPC) API
TOA4 Remote Procedure Call (RPC) API Introduction The purpose of the TOA4 RPC API is to allow external software applications to exchange data with TOA4 and activate certain TOA4 functions. The TOA4 RPC
More informationhca-cli Documentation
hca-cli Documentation Release 0.1.0 James Mackey, Andrey Kislyuk Aug 08, 2018 Contents 1 Installation 3 2 Usage 5 2.1 Configuration management....................................... 5 3 Development 7
More informationHTTP Reading: Section and COS 461: Computer Networks Spring 2013
HTTP Reading: Section 9.1.2 and 9.4.3 COS 461: Computer Networks Spring 2013 1 Recap: Client-Server Communication Client sometimes on Initiates a request to the server when interested E.g., Web browser
More informationWEB SECURITY p.1
WEB SECURITY 101 - p.1 spritzers - CTF team spritz.math.unipd.it/spritzers.html Disclaimer All information presented here has the only purpose to teach how vulnerabilities work. Use them to win CTFs and
More informationcrawly Documentation Release 0.1b Mouad Benchchaoui
crawly Documentation Release 0.1b Mouad Benchchaoui October 25, 2012 CONTENTS i ii Crawly is a Python library that allow to crawl website and extract data from this later using a simple API. Crawly work
More informationTHE CONTEXTUAL DATA SUPPLIER. API Integration Guide
THE CONTEXTUAL DATA SUPPLIER API Integration Guide Contextual Data API v3 April 2018 Overview No Matter if you want to integrate our Contextual Data API into your website with JavaScript or call it from
More informationHuman-Computer Interaction Design
Human-Computer Interaction Design COGS120/CSE170 - Intro. HCI Instructor: Philip Guo Lab 6 - Connecting frontend and backend without page reloads (2016-11-03) by Michael Bernstein, Scott Klemmer, and Philip
More informationCSCI-1680 RPC and Data Representation. Rodrigo Fonseca
CSCI-1680 RPC and Data Representation Rodrigo Fonseca Today Defining Protocols RPC IDL Problem Two programs want to communicate: must define the protocol We have seen many of these, across all layers E.g.,
More informationBrain Corporate Bulk SMS
Brain Corporate Bulk SMS W e S i m p l y D e l i v e r! API Documentation V.2.0 F e b r u a r y 2 0 1 9 2 Table of Contents Sending a Quick Message... 3 API Description... 3 Request Parameter... 4 API
More informationPiqi-RPC. Exposing Erlang services via JSON, XML and Google Protocol Buffers over HTTP. Friday, March 25, 2011
Piqi-RPC Exposing Erlang services via JSON, XML and Google Protocol Buffers over HTTP 1 Anton Lavrik http://piqi.org http://www.alertlogic.com 2 Overview Call Erlang functions using HTTP POST : Server
More informationWeb Sockets and SignalR Building the Real Time Web
Web Sockets and SignalR Building the Real Time Web DDD South West Saturday 26th May 2012 Chris Alcock Agenda Introduction What is Real Time? Interactive? Web Sockets Who What When How? Examples (Client
More informationAPI Documentation. Release Version 1 Beta
API Documentation Release Version 1 Beta Document Version Control Version Date Updated Comment 0.1 April 1, 2016 Initialize document 1 Release version PROMOTEXTER V3 BETA - API Documentation 1 Table of
More informationYahoo Search ATS Plugins. Daniel Morilha and Scott Beardsley
Yahoo Search ATS Plugins Daniel Morilha and Scott Beardsley About Us We have a HUGE team! Serves traffic which generates ~40% of Yahoo s $$$ We run both Search Ingress and Egress Maintain around a dozen
More informationInformation Network Systems The application layer. Stephan Sigg
Information Network Systems The application layer Stephan Sigg Tokyo, November 15, 2012 Introduction 04.10.2012 Introduction to the internet 11.10.2012 The link layer 18.10.2012 The network layer 25.10.2012
More informationElectronic Mail. Three Components: SMTP SMTP. SMTP mail server. 1. User Agents. 2. Mail Servers. 3. SMTP protocol
SMTP Electronic Mail Three Components: 1. User Agents a.k.a. mail reader e.g., gmail, Outlook, yahoo 2. Mail Servers mailbox contains incoming messages for user message queue of outgoing (to be sent) mail
More informationCoding Intro to APIs and REST
DEVNET-3607 Coding 1001 - Intro to APIs and REST Matthew DeNapoli DevNet Developer Evangelist Cisco Spark How Questions? Use Cisco Spark to communicate with the speaker after the session 1. Find this session
More informationWeb Technology. COMP476 Networked Computer Systems. Hypertext and Hypermedia. Document Representation. Client-Server Paradigm.
Web Technology COMP476 Networked Computer Systems - Paradigm The method of interaction used when two application programs communicate over a network. A server application waits at a known address and a
More informationWriting a Protocol Handler
Writing a Protocol Handler A URL object uses a protocol handler to establish a connection with a server and perform whatever protocol is necessary to retrieve data. For example, an HTTP protocol handler
More informationAll requests must be authenticated using the login and password you use to access your account.
The REST API expects all text to be encoded as UTF-8, it is best to test by sending a message with a pound sign ( ) to confirm it is working as expected. If you are having issues sending as plain text,
More informationWeiss Chapter 1 terminology (parenthesized numbers are page numbers)
Weiss Chapter 1 terminology (parenthesized numbers are page numbers) assignment operators In Java, used to alter the value of a variable. These operators include =, +=, -=, *=, and /=. (9) autoincrement
More informationHappyFox API Technical Reference
HappyFox API Technical Reference API Version 1.0 Document Version 0.1 2011, Tenmiles Corporation Copyright Information Under the copyright laws, this manual may not be copied, in whole or in part. Your
More informationIntroducing DataPower GatewayScript. This feature is new for the 7.0 release.
Introducing DataPower GatewayScript. This feature is new for the 7.0 release. DataPower_70_GatewayScript.ppt Page 1 of 26 The agenda for this presentation is as follows. First, we will discuss the goals
More information2- Application Level Protocols HTTP 1.0/1.1/2
2- Application Level Protocols HTTP 1.0/1.1/2 HTTP, (HyperText Transfer Protocol) Basis for fetching Web pages request Network CSE 461 University of Washington 2 Sir Tim Berners-Lee (1955 ) Inventor of
More informationApica ZebraTester. Advanced Load Testing Tool and Cloud Platform
Whether Fortune 100 or the next big startup, Apica s bestin-class load testing and test automation platform helps companies ensure their web and mobile services runs with optimal performance. is an enterprise-level
More informationREST Easy with Infrared360
REST Easy with Infrared360 A discussion on HTTP-based RESTful Web Services and how to use them in Infrared360 What is REST? REST stands for Representational State Transfer, which is an architectural style
More informationReal Life Web Development. Joseph Paul Cohen
Real Life Web Development Joseph Paul Cohen joecohen@cs.umb.edu Index 201 - The code 404 - How to run it? 500 - Your code is broken? 200 - Someone broke into your server? 400 - How are people using your
More information