Struct heroku_rs::endpoints::collaborators::post::TeamCollaboratorCreate [−][src]
pub struct TeamCollaboratorCreate<'a> { pub app_id: &'a str, pub params: TeamCollaboratorCreateParams<'a>, }
Expand description
Team App Collaborator Create
Create a new collaborator on a team app. Use this endpoint instead of the /apps/{app_id_or_name}/collaborator endpoint when you want the collaborator to be granted permissions according to their role in the team.
See Heroku documentation for more information about this endpoint
Example:
TeamCollaboratorCreate takes two required parameters, app_id, user, and returns the created TeamCollaborator
.
use heroku_rs::prelude::*; let permissions = vec!["view"]; let team_app_collab = &TeamCollaboratorCreate::new("APP_ID", "ACCOUNT_ID") .permissions(permissions) .silent(false) .build(); let response = api_client.request(team_app_collab); match response { Ok(success) => println!("Success: {:#?}", success), Err(e) => println!("Error: {}", e), }
See how to create the Heroku api_client
.
Fields
app_id: &'a str
app_id can be the app name or the app id
params: TeamCollaboratorCreateParams<'a>
The parameters to pass to the Heroku API
Implementations
impl<'a> TeamCollaboratorCreate<'a>
[src]
impl<'a> TeamCollaboratorCreate<'a>
[src]Trait Implementations
impl<'a> HerokuEndpoint<TeamCollaborator, (), TeamCollaboratorCreateParams<'a>> for TeamCollaboratorCreate<'a>
[src]
impl<'a> HerokuEndpoint<TeamCollaborator, (), TeamCollaboratorCreateParams<'a>> for TeamCollaboratorCreate<'a>
[src]fn method(&self) -> Method
[src]
fn path(&self) -> String
[src]
fn body(&self) -> Option<TeamCollaboratorCreateParams<'a>>
[src]
fn query(&self) -> Option<QueryType>
[src]
fn url(&self, environment: &ApiEnvironment) -> Url
[src]
fn content_type(&self) -> &str
[src]
fn version(&self) -> &str
[src]
fn agent(&self) -> &str
[src]
Auto Trait Implementations
impl<'a> RefUnwindSafe for TeamCollaboratorCreate<'a>
impl<'a> Send for TeamCollaboratorCreate<'a>
impl<'a> Sync for TeamCollaboratorCreate<'a>
impl<'a> Unpin for TeamCollaboratorCreate<'a>
impl<'a> UnwindSafe for TeamCollaboratorCreate<'a>
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]