payjp_core/account/
requests.rs

1use payjp_client_core::{PayjpClient, BlockingClient, PayjpRequest, RequestBuilder, PayjpMethod};
2
3    /// あなたのアカウント情報を取得します。
4#[derive(Clone,Debug,)]#[derive(serde::Serialize)]
5pub struct RetrieveForMyAccountAccount {
6
7}
8impl RetrieveForMyAccountAccount {
9    /// Construct a new `RetrieveForMyAccountAccount`.
10pub fn new() -> Self {
11    Self {
12        
13    }
14}
15
16}
17    impl Default for RetrieveForMyAccountAccount {
18    fn default() -> Self {
19        Self::new()
20    }
21}impl RetrieveForMyAccountAccount {
22    /// Send the request and return the deserialized response.
23    pub async fn send<C: PayjpClient>(&self, client: &C) -> Result<<Self as PayjpRequest>::Output, C::Err> {
24        self.customize().send(client).await
25    }
26
27    /// Send the request and return the deserialized response, blocking until completion.
28    pub fn send_blocking<C: BlockingClient>(&self, client: &C) -> Result<<Self as PayjpRequest>::Output, C::Err> {
29        self.customize().send_blocking(client)
30    }
31
32    
33}
34
35impl PayjpRequest for RetrieveForMyAccountAccount {
36    type Output = payjp_core::Account;
37
38    fn build(&self) -> RequestBuilder {
39    RequestBuilder::new(PayjpMethod::Get, "/accounts")
40}
41
42}
43