Documentation ¶
Index ¶
- type AddIpToAllowListParam
- type AddIpToAllowListRequest
- type AddIpToAllowListRequestIpsInner
- type ApiService
- func (c *ApiService) AddIpToAllowList(params *AddIpToAllowListParam) (interface{}, error)
- func (c *ApiService) DeleteAllowedIp(params *DeleteAllowedIpParam) (interface{}, error)
- func (c *ApiService) DeleteAllowedIps(params *DeleteAllowedIpsParam) (interface{}, error)
- func (c *ApiService) GetAllowedIp(params *GetAllowedIpParam) (interface{}, error)
- func (c *ApiService) ListAccessActivity(params *ListAccessActivityParam) (interface{}, error)
- func (c *ApiService) ListAllowedIp(params *ListAllowedIpParam) (interface{}, error)
- type DeleteAllowedIpParam
- type DeleteAllowedIpsParam
- type DeleteAllowedIpsRequest
- type ErrorResponse
- type ErrorResponseErrorsInner
- type GetAllowedIpParam
- type IpAccessManagement2xx
- type IpAccessManagement2xxResultInner
- type ListAccessActivity200Response
- type ListAccessActivity200ResponseResultInner
- type ListAccessActivityParam
- type ListAllowedIpParam
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddIpToAllowListParam ¶
type AddIpToAllowListParam struct { // The `on-behalf-of` header allows you to make API calls from a parent account on behalf of the parent's Subusers or customer accounts. You will use the parent account's API key when using this header. When making a call on behalf of a customer account, the property value should be \"account-id\" followed by the customer account's ID (e.g., `on-behalf-of: account-id <account-id>`). When making a call on behalf of a Subuser, the property value should be the Subuser's username (e.g., `on-behalf-of: <subuser-username>`). See [**On Behalf Of**](https://docs.sendgrid.com/api-reference/how-to-use-the-sendgrid-v3-api/on-behalf-of) for more information. Onbehalfof *string `json:"on-behalf-of,omitempty"` // AddIpToAllowListRequest *AddIpToAllowListRequest `json:"AddIpToAllowListRequest,omitempty"` }
func (*AddIpToAllowListParam) SetAddIpToAllowListRequest ¶
func (params *AddIpToAllowListParam) SetAddIpToAllowListRequest(AddIpToAllowListRequest AddIpToAllowListRequest) *AddIpToAllowListParam
func (*AddIpToAllowListParam) SetOnbehalfof ¶
func (params *AddIpToAllowListParam) SetOnbehalfof(Onbehalfof string) *AddIpToAllowListParam
type AddIpToAllowListRequest ¶
type AddIpToAllowListRequest struct { // An array containing the IP(s) you want to allow. Ips []AddIpToAllowListRequestIpsInner `json:"ips"` }
AddIpToAllowListRequest struct for AddIpToAllowListRequest
type AddIpToAllowListRequestIpsInner ¶
type AddIpToAllowListRequestIpsInner struct { // An IP address that you want to allow. Ip string `json:"ip"` }
AddIpToAllowListRequestIpsInner struct for AddIpToAllowListRequestIpsInner
type ApiService ¶
type ApiService struct {
// contains filtered or unexported fields
}
func NewApiService ¶
func NewApiService(requestHandler *sendgrid.RequestHandler) *ApiService
func NewApiServiceWithClient ¶
func NewApiServiceWithClient(client sendgrid.BaseClient) *ApiService
func (*ApiService) AddIpToAllowList ¶
func (c *ApiService) AddIpToAllowList(params *AddIpToAllowListParam) (interface{}, error)
**This endpoint allows you to add one or more allowed IP addresses.** To allow one or more IP addresses, pass them to this endpoint in an array. Once an IP address is added to your allow list, it will be assigned an `id` that can be used to remove the address. You can retrieve the ID associated with an IP using the \"Retrieve a list of currently allowed IPs\" endpoint.
func (*ApiService) DeleteAllowedIp ¶
func (c *ApiService) DeleteAllowedIp(params *DeleteAllowedIpParam) (interface{}, error)
**This endpoint allows you to remove a specific IP address from your list of allowed addresses.** When removing a specific IP address from your list, you must include the ID in your call. You can retrieve the IDs associated with your allowed IP addresses using the \"Retrieve a list of currently allowed IPs\" endpoint.
func (*ApiService) DeleteAllowedIps ¶
func (c *ApiService) DeleteAllowedIps(params *DeleteAllowedIpsParam) (interface{}, error)
**This endpoint allows you to remove one or more IP addresses from your list of allowed addresses.** To remove one or more IP addresses, pass this endpoint an array containing the ID(s) associated with the IP(s) you intend to remove. You can retrieve the IDs associated with your allowed IP addresses using the \"Retrieve a list of currently allowed IPs\" endpoint. It is possible to remove your own IP address, which will block access to your account. You will need to submit a [support ticket](https://sendgrid.com/docs/ui/account-and-settings/support/) if this happens. For this reason, it is important to double check that you are removing only the IPs you intend to remove when using this endpoint.
func (*ApiService) GetAllowedIp ¶
func (c *ApiService) GetAllowedIp(params *GetAllowedIpParam) (interface{}, error)
**This endpoint allows you to retreive a specific IP address that has been allowed to access your account.** You must include the ID for the specific IP address you want to retrieve in your call. You can retrieve the IDs associated with your allowed IP addresses using the \"Retrieve a list of currently allowed IPs\" endpoint.
func (*ApiService) ListAccessActivity ¶
func (c *ApiService) ListAccessActivity(params *ListAccessActivityParam) (interface{}, error)
**This endpoint allows you to retrieve a list of all of the IP addresses that recently attempted to access your account either through the User Interface or the API.**
func (*ApiService) ListAllowedIp ¶
func (c *ApiService) ListAllowedIp(params *ListAllowedIpParam) (interface{}, error)
**This endpoint allows you to retrieve a list of IP addresses that are currently allowed to access your account.** Each IP address returned to you will have `created_at` and `updated_at` dates. Each IP will also be associated with an `id` that can be used to remove the address from your allow list.
type DeleteAllowedIpParam ¶
type DeleteAllowedIpParam struct { // The ID of the allowed IP address that you want to retrieve. RuleId *string `json:"rule_id"` // The `on-behalf-of` header allows you to make API calls from a parent account on behalf of the parent's Subusers or customer accounts. You will use the parent account's API key when using this header. When making a call on behalf of a customer account, the property value should be \"account-id\" followed by the customer account's ID (e.g., `on-behalf-of: account-id <account-id>`). When making a call on behalf of a Subuser, the property value should be the Subuser's username (e.g., `on-behalf-of: <subuser-username>`). See [**On Behalf Of**](https://docs.sendgrid.com/api-reference/how-to-use-the-sendgrid-v3-api/on-behalf-of) for more information. Onbehalfof *string `json:"on-behalf-of,omitempty"` }
func (*DeleteAllowedIpParam) SetOnbehalfof ¶
func (params *DeleteAllowedIpParam) SetOnbehalfof(Onbehalfof string) *DeleteAllowedIpParam
func (*DeleteAllowedIpParam) SetRuleId ¶
func (params *DeleteAllowedIpParam) SetRuleId(RuleId string) *DeleteAllowedIpParam
type DeleteAllowedIpsParam ¶
type DeleteAllowedIpsParam struct { // The `on-behalf-of` header allows you to make API calls from a parent account on behalf of the parent's Subusers or customer accounts. You will use the parent account's API key when using this header. When making a call on behalf of a customer account, the property value should be \"account-id\" followed by the customer account's ID (e.g., `on-behalf-of: account-id <account-id>`). When making a call on behalf of a Subuser, the property value should be the Subuser's username (e.g., `on-behalf-of: <subuser-username>`). See [**On Behalf Of**](https://docs.sendgrid.com/api-reference/how-to-use-the-sendgrid-v3-api/on-behalf-of) for more information. Onbehalfof *string `json:"on-behalf-of,omitempty"` // DeleteAllowedIpsRequest *DeleteAllowedIpsRequest `json:"DeleteAllowedIpsRequest,omitempty"` }
func (*DeleteAllowedIpsParam) SetDeleteAllowedIpsRequest ¶
func (params *DeleteAllowedIpsParam) SetDeleteAllowedIpsRequest(DeleteAllowedIpsRequest DeleteAllowedIpsRequest) *DeleteAllowedIpsParam
func (*DeleteAllowedIpsParam) SetOnbehalfof ¶
func (params *DeleteAllowedIpsParam) SetOnbehalfof(Onbehalfof string) *DeleteAllowedIpsParam
type DeleteAllowedIpsRequest ¶
type DeleteAllowedIpsRequest struct { // An array of the IDs of the IP address that you want to remove from your allow list. Ids *[]int32 `json:"ids,omitempty"` }
DeleteAllowedIpsRequest struct for DeleteAllowedIpsRequest
type ErrorResponse ¶
type ErrorResponse struct { Errors *[]ErrorResponseErrorsInner `json:"errors,omitempty"` // When applicable, this property value will be an error ID. Id *string `json:"id,omitempty"` }
ErrorResponse struct for ErrorResponse
type ErrorResponseErrorsInner ¶
type ErrorResponseErrorsInner struct { // An error message. Message *string `json:"message,omitempty"` // When applicable, this property value will be the field that generated the error. Field *string `json:"field,omitempty"` // When applicable, this property value will be helper text or a link to documentation to help you troubleshoot the error. Help *map[string]interface{} `json:"help,omitempty"` }
ErrorResponseErrorsInner struct for ErrorResponseErrorsInner
type GetAllowedIpParam ¶
type GetAllowedIpParam struct { // The ID of the allowed IP address that you want to retrieve. RuleId *string `json:"rule_id"` // The `on-behalf-of` header allows you to make API calls from a parent account on behalf of the parent's Subusers or customer accounts. You will use the parent account's API key when using this header. When making a call on behalf of a customer account, the property value should be \"account-id\" followed by the customer account's ID (e.g., `on-behalf-of: account-id <account-id>`). When making a call on behalf of a Subuser, the property value should be the Subuser's username (e.g., `on-behalf-of: <subuser-username>`). See [**On Behalf Of**](https://docs.sendgrid.com/api-reference/how-to-use-the-sendgrid-v3-api/on-behalf-of) for more information. Onbehalfof *string `json:"on-behalf-of,omitempty"` }
func (*GetAllowedIpParam) SetOnbehalfof ¶
func (params *GetAllowedIpParam) SetOnbehalfof(Onbehalfof string) *GetAllowedIpParam
func (*GetAllowedIpParam) SetRuleId ¶
func (params *GetAllowedIpParam) SetRuleId(RuleId string) *GetAllowedIpParam
type IpAccessManagement2xx ¶
type IpAccessManagement2xx struct { // An array listing one or more of your allowed IPs. Result *[]IpAccessManagement2xxResultInner `json:"result,omitempty"` }
IpAccessManagement2xx struct for IpAccessManagement2xx
type IpAccessManagement2xxResultInner ¶
type IpAccessManagement2xxResultInner struct { // The ID of the allowed IP. Id *int32 `json:"id,omitempty"` // The allowed IP. Ip *string `json:"ip,omitempty"` // A Unix timestamp indicating when the IP was added to the allow list. CreatedAt *int32 `json:"created_at,omitempty"` // A Unix timestamp indicating when the IPs allow status was most recently updated. UpdatedAt *int32 `json:"updated_at,omitempty"` }
IpAccessManagement2xxResultInner struct for IpAccessManagement2xxResultInner
type ListAccessActivity200Response ¶
type ListAccessActivity200Response struct { // An array containing the IPs that recently attempted to access your account. Result []ListAccessActivity200ResponseResultInner `json:"result"` }
ListAccessActivity200Response struct for ListAccessActivity200Response
type ListAccessActivity200ResponseResultInner ¶
type ListAccessActivity200ResponseResultInner struct { // Indicates if the IP address was granted access to the account. Allowed bool `json:"allowed"` // The authentication method used when attempting access. AuthMethod string `json:"auth_method"` // A Unix timestamp indicating when the first access attempt was made. FirstAt int32 `json:"first_at"` // The IP addressed used during the access attempt. Ip string `json:"ip"` // A Unix timestamp indicating when the most recent access attempt was made LastAt int32 `json:"last_at"` // The geographic location from which the access attempt originated. Location string `json:"location"` }
ListAccessActivity200ResponseResultInner struct for ListAccessActivity200ResponseResultInner
type ListAccessActivityParam ¶
type ListAccessActivityParam struct { // Limits the number of IPs to return. Limit *int32 `json:"limit,omitempty"` // The `on-behalf-of` header allows you to make API calls from a parent account on behalf of the parent's Subusers or customer accounts. You will use the parent account's API key when using this header. When making a call on behalf of a customer account, the property value should be \"account-id\" followed by the customer account's ID (e.g., `on-behalf-of: account-id <account-id>`). When making a call on behalf of a Subuser, the property value should be the Subuser's username (e.g., `on-behalf-of: <subuser-username>`). See [**On Behalf Of**](https://docs.sendgrid.com/api-reference/how-to-use-the-sendgrid-v3-api/on-behalf-of) for more information. Onbehalfof *string `json:"on-behalf-of,omitempty"` }
func (*ListAccessActivityParam) SetLimit ¶
func (params *ListAccessActivityParam) SetLimit(Limit int32) *ListAccessActivityParam
func (*ListAccessActivityParam) SetOnbehalfof ¶
func (params *ListAccessActivityParam) SetOnbehalfof(Onbehalfof string) *ListAccessActivityParam
type ListAllowedIpParam ¶
type ListAllowedIpParam struct { // The `on-behalf-of` header allows you to make API calls from a parent account on behalf of the parent's Subusers or customer accounts. You will use the parent account's API key when using this header. When making a call on behalf of a customer account, the property value should be \"account-id\" followed by the customer account's ID (e.g., `on-behalf-of: account-id <account-id>`). When making a call on behalf of a Subuser, the property value should be the Subuser's username (e.g., `on-behalf-of: <subuser-username>`). See [**On Behalf Of**](https://docs.sendgrid.com/api-reference/how-to-use-the-sendgrid-v3-api/on-behalf-of) for more information. Onbehalfof *string `json:"on-behalf-of,omitempty"` }
func (*ListAllowedIpParam) SetOnbehalfof ¶
func (params *ListAllowedIpParam) SetOnbehalfof(Onbehalfof string) *ListAllowedIpParam
Source Files ¶
- api_add_ip_to_allow_list.go
- api_delete_allowed_ip.go
- api_delete_allowed_ips.go
- api_get_allowed_ip.go
- api_list_access_activity.go
- api_list_allowed_ip.go
- api_service.go
- model_add_ip_to_allow_list_request.go
- model_add_ip_to_allow_list_request_ips_inner.go
- model_delete_allowed_ips_request.go
- model_error_response.go
- model_error_response_errors_inner.go
- model_ip_access_management2xx.go
- model_ip_access_management2xx_result_inner.go
- model_list_access_activity_200_response.go
- model_list_access_activity_200_response_result_inner.go