rustsf 0.1.1

Salesforce SDK for Rust, supports the latest API version 68.0, (Winter 2026)
Documentation
use crate::rest_api::HTTPMethod;
use crate::{Error, RestApi};
use std::collections::HashMap;
use std::fmt::Debug;
use reqwest::Response;
use serde::Serialize;

impl RestApi {
	pub async fn apex_rest<T: Debug + Serialize>(
		&self,
		method: HTTPMethod,
		url: &str,
		data: &T,
		headers: &HashMap<String, String>,
	) -> Result<Response, Error> {
		let url = format!("services/apexrest/{}", url);

		self.send(
			method,
			url,
			data,
			headers,
		).await
	}
}