// List all the organization memberships of the given organization.
List all the organization memberships of the given organization.
// List all the organization memberships of the given organization .
func (s *organizationMemberships) List(ctx context.Context, organization string, options OrganizationMembershipListOptions) (*OrganizationMembershipList, error) {
	if !validStringID(&organization) {
		return nil, errors.New("invalid value for organization")
	}
	u := fmt.Sprintf("organizations/%s/organization-memberships", url.QueryEscape(organization))
	req, err := s.client.newRequest("GET", u, &options)
	if err != nil {
		return nil, err
	}
	ml := &OrganizationMembershipList{}
	err = s.client.do(ctx, req, ml)
	if err != nil {
		return nil, err
	}
	return ml, nil
}
func ( s * organizationMemberships ) List ( ctx context . Context , organization string , options OrganizationMembershipListOptions ) ( * OrganizationMembershipList , error ) { if ! validStringID ( & organization ) { return nil , errors . New ( " " ) } u := fmt . Sprintf ( " " , url . QueryEscape ( organization ) ) req , err := s . client . newRequest ( " " , u , & options ) if err != nil { return nil , err } ml := & OrganizationMembershipList { } err = s . client . do ( ctx , req , ml ) if err != nil { return nil , err } return ml , nil }
List all the organization memberships of the given organization.
List all the organization memberships of the given organization .