mirror of
https://github.com/dathere/ckanaction.git
synced 2026-05-20 09:54:14 +00:00
fix: update docs and errors with CKANError
This commit is contained in:
parent
677475f750
commit
e5d4f8d442
5 changed files with 18 additions and 11 deletions
|
|
@ -11,10 +11,11 @@ This means that instead of using generic request library crates such as `reqwest
|
|||
For example the following code can be ran to send an HTTP POST request to the `/package_list` endpoint of a local CKAN instance's API by using the `ckanaction` crate:
|
||||
|
||||
```rust
|
||||
use ckanaction::CKANError;
|
||||
use dotenvy::dotenv;
|
||||
|
||||
#[tokio::main]
|
||||
async fn main() -> Result<(), Box<dyn std::error::Error>> {
|
||||
async fn main() -> Result<(), CKANError> {
|
||||
// Load environment variables from .env file
|
||||
dotenv()?;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue