Skip to content

Commit

Permalink
Rust README
Browse files Browse the repository at this point in the history
  • Loading branch information
tuck1s committed Jul 5, 2020
1 parent 5fdbc03 commit b290fc2
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions snippets/recipient-validation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,20 @@ If you build and execute the code included in the repo, the result should look l

This uses the reqwest library with Tokio async (similar to [this](https://rust-lang-nursery.github.io/rust-cookbook/web/clients/requests.html)), as it does not seem possible to set request headers on the blocking `get` call.

The example includes a cargo package manager [configuration file](rust_recipient_validation/Cargo.toml), so you can build and run with:`

```
cd rust_recipient_validation
cargo run
Finished dev [unoptimized + debuginfo] target(s) in 0.10s
Running `target/debug/rust_recipient_validation`
Status: 200 OK
Body:
{"results":{"valid":false,"is_role":true,"is_disposable":false,"is_free":true,"reason":"Invalid Recipient","result":"undeliverable"}}
```

## Summary
You made is this far, you earn the honorary badge of [Codefox 🦊](https://en.wikipedia.org/wiki/The_Hedgehog_and_the_Fox)!

Expand Down

0 comments on commit b290fc2

Please sign in to comment.