jaguar_resty 1.1.6 copy "jaguar_resty: ^1.1.6" to clipboard
jaguar_resty: ^1.1.6 copied to clipboard

outdatedDart 1 only

Build fluent functional Restful clients

jaguar_resty #

Build fluent functional Restful clients

Features #

  • Fluent API to set:
    • Hierarchical paths
    • Query parameters
    • Headers
    • Body
    • Client
  • JSON request encoding
  • JSON request decoding
  • URL encoded forms
  • Multipart form
  • Cookie jar
  • Interceptors
  • Authenticators

Usage #

Simple GET request #

Book book = await resty.get('/book/1').fetch(Book.map);

Add query parameters #

Book book = await resty.get('/book').query('page', '2').fetchList(Book.map);

Add headers #

Book book = await resty.get('/book').header('page', '2').fetch(Book.map);

JSON request encoding #

Book book = await resty.post('/book').json(new Book('1', 'Harry potter'))
  .fetch(Book.map);

JSON response decoding #

Book book = await resty.get('/book/1').fetch(Book.map);

URL encoded forms #

// TODO WIP

Multipart form #

// TODO WIP
0
likes
0
pub points
58%
popularity

Publisher

unverified uploader

Build fluent functional Restful clients

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

async, client_cookie, http, http_parser

More

Packages that depend on jaguar_resty