types

package
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 1, 2020 License: MPL-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const APPLICATION_SHORT_NAME = "mpt"
View Source
const CONNECT_TYPE_AWS_HOSTED_CONNECTION string = "AWSHC"
View Source
const CONNECT_TYPE_AWS_VIF string = "AWS"
View Source
const LAG_PORT string = "LAG"
View Source
const MODIFY_A_END_VLAN = "A_VLAN"
View Source
const MODIFY_B_END_VLAN = "B_VLAN"
View Source
const MODIFY_COST_CENTRE = "COST_CENTRE"
View Source
const MODIFY_MARKETPLACE_VISIBILITY string = "MARKETPLACE_VISIBILITY"
View Source
const MODIFY_NAME string = "NAME"
View Source
const MODIFY_RATE_LIMIT = "RATE_LIMIT"
View Source
const PRODUCT_IX = "ix"
View Source
const PRODUCT_MCR = "mcr2"
View Source
const PRODUCT_MEGAPORT = "megaport"
View Source
const PRODUCT_VXC = "vxc"
View Source
const SINGLE_PORT string = "Single"
View Source
const STATUS_CANCELLED string = "CANCELLED"
View Source
const STATUS_DECOMMISSIONED string = "DECOMMISSIONED"

Variables

This section is empty.

Functions

This section is empty.

Types

type AWSHostedVIFOrder

type AWSHostedVIFOrder struct {
	AssociatedVXCs []AWSHostedVIFOrderConfiguration `json:"associatedVxcs"`
	PortID         string                           `json:"productUid"`
}

type AWSHostedVIFOrderBEndConfiguration

type AWSHostedVIFOrderBEndConfiguration struct {
	ProductUID    string                         `json:"productUid"`
	PartnerConfig AWSHostedVIFOrderPartnerConfig `json:"partnerConfig"`
}

type AWSHostedVIFOrderConfiguration

type AWSHostedVIFOrderConfiguration struct {
	Name      string                             `json:"productName"`
	RateLimit int                                `json:"rateLimit"`
	AEnd      VXCOrderAEndConfiguration          `json:"aEnd"`
	BEnd      AWSHostedVIFOrderBEndConfiguration `json:"bEnd"`
}

type AWSHostedVIFOrderPartnerConfig

type AWSHostedVIFOrderPartnerConfig struct {
	ConnectType       string `json:"connectType"`
	Type              string `json:"type"`
	ASN               int    `json:"asn"`
	AmazonASN         int    `json:"amazonAsn"`
	OwnerAccount      string `json:"ownerAccount"`
	AuthKey           string `json:"authKey,omitempty"`
	Prefixes          string `json:"prefixes,omitempty"`
	CustomerIPAddress string `json:"customerIpAddress,omitempty"`
	AmazonIPAddress   string `json:"amazonIpAddress,omitempty"`
}

type CompanyEnablement

type CompanyEnablement struct {
	TradingName string `json:"tradingName"`
}

type Country

type Country struct {
	Code      string `json:"code"`
	Name      string `json:"name"`
	Prefix    string `json:"prefix"`
	SiteCount int    `json:"siteCount"`
}

type CountryInnerResponse

type CountryInnerResponse struct {
	Countries     []Country `json:"countries"`
	NetworkRegion string    `json:"networkRegion"`
}

type CountryResponse

type CountryResponse struct {
	Message string                 `json:"message"`
	Terms   string                 `json:"terms"`
	Data    []CountryInnerResponse `json:"data"`
}

type ErrorResponse

type ErrorResponse struct {
	Message string `json:"message"`
	Terms   string `json:"terms"`
	Data    string `json:"data"`
}

type GenericResponse

type GenericResponse struct {
	Message string                 `json:"message"`
	Terms   string                 `json:"terms"`
	Data    map[string]interface{} `json:"data"`
}

type Location

type Location struct {
	Name             string                 `json:"name"`
	Country          string                 `json:"country"`
	LiveDate         int                    `json:"liveDate"`
	SiteCode         string                 `json:"siteCode"`
	NetworkRegion    string                 `json:"networkRegion"`
	Address          map[string]string      `json:"address"`
	Campus           string                 `json:"campus"`
	Latitude         float64                `json:"latitude"`
	Longitude        float64                `json:"longitude"`
	Products         map[string]interface{} `json:"products"`
	Market           string                 `json:"market"`
	Metro            string                 `json:"metro"`
	VRouterAvailable bool                   `json:"vRouterAvailable"`
	ID               int                    `json:"id"`
	Status           string                 `json:"status"`
}

type LocationResponse

type LocationResponse struct {
	Message string     `json:"message"`
	Terms   string     `json:"terms"`
	Data    []Location `json:"data"`
}

type MCR

type MCR struct {
	ID                    int               `json:"productId"`
	UID                   string            `json:"productUid"`
	Name                  string            `json:"productName"`
	Type                  string            `json:"productType"`
	ProvisioningStatus    string            `json:"provisioningStatus"`
	CreateDate            int               `json:"createDate"`
	CreatedBy             string            `json:"createdBy"`
	PortSpeed             int               `json:"portSpeed"`
	TerminateDate         int               `json:"terminateDate"`
	LiveDate              int               `json:"liveDate"`
	Market                string            `json:"market"`
	LocationID            int               `json:"locationId"`
	UsageAlgorithm        string            `json:"usageAlgorithm"`
	MarketplaceVisibility bool              `json:"marketplaceVisibility"`
	VXCPermitted          bool              `json:"vxcpermitted"`
	VXCAutoApproval       bool              `json:"vxcAutoApproval"`
	SecondaryName         string            `json:"secondaryName"`
	LAGPrimary            bool              `json:"lagPrimary"`
	LAGID                 int               `json:"lagId"`
	AggregationID         int               `json:"aggregationId"`
	CompanyUID            string            `json:"companyUid"`
	CompanyName           string            `json:"companyName"`
	ContractStartDate     int               `json:"contractStartDate"`
	ContractEndDate       int               `json:"contractEndDate"`
	ContractTermMonths    int               `json:"contractTermMonths"`
	AttributeTags         map[string]string `json:"attributeTags"`
	Virtual               bool              `json:"virtual"`
	BuyoutPort            bool              `json:"buyoutPort"`
	Locked                bool              `json:"locked"`
	AdminLocked           bool              `json:"adminLocked"`
	Cancelable            bool              `json:"cancelable"`
	Resources             MCRResources      `json:"resources"`
}

type MCROrder

type MCROrder struct {
	LocationID int            `json:"locationId"`
	Name       string         `json:"productName"`
	Type       string         `json:"productType"`
	PortSpeed  int            `json:"portSpeed"`
	Config     MCROrderConfig `json:"config"`
}

type MCROrderConfig

type MCROrderConfig struct {
	ASN int `json:"mcrAsn,omitempty"`
}

type MCROrderConfirmation

type MCROrderConfirmation struct {
	TechnicalServiceUID string `json:"technicalServiceUid"`
}

type MCROrderResponse

type MCROrderResponse struct {
	Message string                 `json:"message"`
	Terms   string                 `json:"terms"`
	Data    []MCROrderConfirmation `json:"data"`
}

type MCRResources

type MCRResources struct {
	Interface     PortInterface    `json:"interface"`
	VirtualRouter MCRVirtualRouter `json:"virtual_router"`
}

type MCRResponse

type MCRResponse struct {
	Message string `json:"message"`
	Terms   string `json:"terms"`
	Data    MCR    `json:"data"`
}

type MCRVirtualRouter

type MCRVirtualRouter struct {
	ID           int    `json:"id"`
	ASN          int    `json:"mcrAsn"`
	Name         string `json:"name"`
	ResourceName string `json:"resource_name"`
	ResourceType string `json:"resource_type"`
	Speed        int    `json:"speed"`
}

type Market

type Market struct {
	Currency               string `json:"currencyEnum"`
	Language               string `json:"language"`
	CompanyLegalIdentifier string `json:"companyLegalIdentifier"`
	CompanyLegalName       string `json:"companyLegalName"`
	BillingContactName     string `json:"billingContactName"`
	BillingContactPhone    string `json:"billingContactPhone"`
	BillingContactEmail    string `json:"billingContactEmail"`
	AddressLine1           string `json:"address1"`
	AddressLine2           string `json:"address2"`
	City                   string `json:"city"`
	State                  string `json:"state"`
	Postcode               string `json:"postcode"`
	Country                string `json:"country"`
	PONumber               string `json:"yourPoNumber"`
	TaxNumber              string `json:"taxNumber"`
	FirstPartyID           int    `json:"firstPartyId"`
}

type MegaportApiClient

type MegaportApiClient struct {
	Environment string
	Url         string
	HttpClient  *http.Client
	UserAgent   string
}

type PartnerLookup

type PartnerLookup struct {
	Bandwidth    int                 `json:"bandwidth"`
	Bandwidths   []int               `json:"bandwidths"`
	Megaports    []PartnerLookupItem `json:"megaports"`
	Peers        []interface{}       `json:"peers"`
	ResourceType string              `json:"resource_type"`
	ServiceKey   string              `json:"service_key"`
	VLAN         int                 `json:"vlan"`
}

type PartnerLookupItem

type PartnerLookupItem struct {
	ID          int    `json:"port"`
	Type        string `json:"type"`
	VXC         int    `json:"vxc"`
	ProductID   int    `json:"productId"`
	ProductUID  string `json:"productUid"`
	Name        string `json:"name"`
	ServiceID   int    `json:"nServiceId"`
	Description string `json:"description"`
	CompanyID   int    `json:"companyId"`
	CompanyName string `json:"companyName"`
	PortSpeed   int    `json:"portSpeed"`
	LocationID  int    `json:"locationId"`
	State       string `json:"state"`
	Country     string `json:"country"`
}

type PartnerLookupResponse

type PartnerLookupResponse struct {
	Message string        `json:"message"`
	Data    PartnerLookup `json:"data"`
	Terms   string        `json:"terms"`
}

type PartnerMegaport

type PartnerMegaport struct {
	ConnectType  string `json:"connectType"`
	ProductUID   string `json:"productUid"`
	ProductName  string `json:"title"`
	CompanyUID   string `json:"companyUid"`
	CompanyName  string `json:"companyName"`
	LocationId   int    `json:"locationId"`
	Speed        int    `json:"speed"`
	Rank         int    `json:"rank"`
	VXCPermitted bool   `json:"vxcPermitted"`
}

type PartnerMegaportResponse

type PartnerMegaportResponse struct {
	Message string            `json:"message"`
	Terms   string            `json:"terms"`
	Data    []PartnerMegaport `json:"data"`
}

type PartnerOrder

type PartnerOrder struct {
	PortID         string                 `json:"productUid"`
	AssociatedVXCs []PartnerOrderContents `json:"associatedVxcs"`
}

type PartnerOrderAEndConfiguration

type PartnerOrderAEndConfiguration struct {
	VLAN int `json:"vlan,omitempty"`
}

type PartnerOrderAzurePartnerConfig

type PartnerOrderAzurePartnerConfig struct {
	ConnectType string              `json:"connectType"`
	ServiceKey  string              `json:"serviceKey"`
	Peers       []map[string]string `json:"peers"`
}

type PartnerOrderBEndConfiguration

type PartnerOrderBEndConfiguration struct {
	PartnerPortID string      `json:"productUid"`
	PartnerConfig interface{} `json:"partnerConfig"`
}

type PartnerOrderContents

type PartnerOrderContents struct {
	Name      string                        `json:"productName"`
	RateLimit int                           `json:"rateLimit"`
	AEnd      PartnerOrderAEndConfiguration `json:"aEnd"`
	BEnd      PartnerOrderBEndConfiguration `json:"bEnd"`
}

type PartnerOrderGooglePartnerConfig

type PartnerOrderGooglePartnerConfig struct {
	ConnectType string `json:"connectType"`
	PairingKey  string `json:"pairingKey"`
}

type PartnerVXCUpdate

type PartnerVXCUpdate struct {
	Name      string `json:"name"`
	RateLimit int    `json:"rateLimit"`
	AEndVLAN  int    `json:"aEndVlan"`
}

type Port

type Port struct {
	ID                    int               `json:"productId"`
	UID                   string            `json:"productUid"`
	Name                  string            `json:"productName"`
	Type                  string            `json:"productType"`
	ProvisioningStatus    string            `json:"provisioningStatus"`
	CreateDate            int               `json:"createDate"`
	CreatedBy             string            `json:"createdBy"`
	PortSpeed             int               `json:"portSpeed"`
	TerminateDate         int               `json:"terminateDate"`
	LiveDate              int               `json:"liveDate"`
	Market                string            `json:"market"`
	LocationID            int               `json:"locationId"`
	UsageAlgorithm        string            `json:"usageAlgorithm"`
	MarketplaceVisibility bool              `json:"marketplaceVisibility"`
	VXCPermitted          bool              `json:"vxcpermitted"`
	VXCAutoApproval       bool              `json:"vxcAutoApproval"`
	SecondaryName         string            `json:"secondaryName"`
	LAGPrimary            bool              `json:"lagPrimary"`
	LAGID                 int               `json:"lagId"`
	AggregationID         int               `json:"aggregationId"`
	CompanyUID            string            `json:"companyUid"`
	CompanyName           string            `json:"companyName"`
	ContractStartDate     int               `json:"contractStartDate"`
	ContractEndDate       int               `json:"contractEndDate"`
	ContractTermMonths    int               `json:"contractTermMonths"`
	AttributeTags         map[string]string `json:"attributeTags"`
	Virtual               bool              `json:"virtual"`
	BuyoutPort            bool              `json:"buyoutPort"`
	Locked                bool              `json:"locked"`
	AdminLocked           bool              `json:"adminLocked"`
	Cancelable            bool              `json:"cancelable"`
	VXCResources          PortResources     `json:"resources"`
}

type PortInterface

type PortInterface struct {
	Demarcation  string `json:"demarcation"`
	Description  string `json:"description"`
	ID           int    `json:"id"`
	LOATemplate  string `json:"loa_template"`
	Media        string `json:"media"`
	Name         string `json:"name"`
	PortSpeed    int    `json:"port_speed"`
	ResourceName string `json:"resource_name"`
	ResourceType string `json:"resource_type"`
	Up           int    `json:"up"`
}

type PortOrder

type PortOrder struct {
	Name                  string `json:"productName"`
	Term                  int    `json:"term"`
	ProductType           string `json:"productType"`
	PortSpeed             int    `json:"portSpeed"`
	LocationID            int    `json:"locationId"`
	CreateDate            int64  `json:"createDate"`
	Virtual               bool   `json:"virtual"`
	Market                string `json:"market"`
	LagPortCount          int    `json:"lagPortCount,omitempty"`
	MarketplaceVisibility bool   `json:"marketplaceVisibility"`
}

type PortOrderConfirmation

type PortOrderConfirmation struct {
	TechnicalServiceUID string `json:"technicalServiceUid"`
}

type PortOrderResponse

type PortOrderResponse struct {
	Message string                  `json:"message"`
	Terms   string                  `json:"terms"`
	Data    []PortOrderConfirmation `json:"data"`
}

type PortResources

type PortResources struct {
	Interface PortInterface `json:"interface"`
}

type PortResourcesInterface

type PortResourcesInterface struct {
	Demarcation  string `json:"demarcation"`
	Description  string `json:"description"`
	ID           int    `json:"id"`
	LOATemplate  string `json:"loa_template"`
	Media        string `json:"media"`
	Name         string `json:"name"`
	PortSpeed    int    `json:"port_speed"`
	ResourceName string `json:"resource_name"`
	ResourceType string `json:"resource_type"`
	Up           int    `json:"up"`
}

type PortResponse

type PortResponse struct {
	Message string `json:"message"`
	Terms   string `json:"terms"`
	Data    Port   `json:"data"`
}

type ProductUpdate

type ProductUpdate struct {
	Name                 string `json:"name"`
	CostCentre           string `json:"costCentre"`
	MarketplaceVisbility bool   `json:"marketplaceVisibility"`
}

type VLLConfig

type VLLConfig struct {
	AEndVLAN      int    `json:"a_vlan"`
	BEndVLAN      int    `json:"b_vlan"`
	Description   string `json:"description"`
	ID            int    `json:"id"`
	Name          string `json:"name"`
	RateLimitMBPS int    `json:"rate_limit_mbps"`
	ResourceName  string `json:"resource_name"`
	ResourceType  string `json:"resource_type"`
}

type VXC

type VXC struct {
	ID                 int                 `json:"productId"`
	UID                string              `json:"productUid"`
	ServiceID          int                 `json:"nServiceId"`
	Name               string              `json:"productName"`
	Type               string              `json:"productType"`
	RateLimit          int                 `json:"rateLimit"`
	DistanceBand       string              `json:"distanceBand"`
	ProvisioningStatus string              `json:"provisioningStatus"`
	AEndConfiguration  VXCEndConfiguration `json:"aEnd"`
	BEndConfiguration  VXCEndConfiguration `json:"bEnd"`
	SecondaryName      string              `json:"secondaryName"`
	UsageAlgorithm     string              `json:"usageAlgorithm"`
	CreatedBy          string              `json:"createdBy"`
	LiveDate           int                 `json:"liveDate"`
	CreateDate         int                 `json:"createDate"`
	Resources          VXCResources        `json:"resources"`
	VXCApproval        VXCApproval         `json:"vxcApproval"`
	ContractStartDate  int                 `json:"contractStartDate"`
	ContractEndDate    int                 `json:"contractEndDate"`
	ContractTermMonths int                 `json:"contractTermMonths"`
	CompanyUID         string              `json:"companyUid"`
	CompanyName        string              `json:"companyName"`
	Locked             bool                `json:"locked"`
	AdminLocked        bool                `json:"adminLocked"`
	AttributeTags      map[string]string   `json:"attributeTags"`
	Cancelable         bool                `json:"cancelable"`
}

---- VXC Detail Types //

type VXCApproval

type VXCApproval struct {
	Status   string `json:"status"`
	Message  string `json:"message"`
	UID      string `json:"uid"`
	Type     string `json:"type"`
	NewSpeed int    `json:"newSpeed"`
}

type VXCConfiguration

type VXCConfiguration struct {
	Name      string                    `json:"productName"`
	RateLimit int                       `json:"rateLimit"`
	AEnd      VXCOrderAEndConfiguration `json:"aEnd"`
	BEnd      VXCOrderBEndConfiguration `json:"bEnd"`
}

type VXCEndConfiguration

type VXCEndConfiguration struct {
	OwnerUID      string `json:"ownerUid"`
	UID           string `json:"productUid"`
	Name          string `json:"productName"`
	LocationID    int    `json:"locationId"`
	Location      string `json:"location"`
	VLAN          int    `json:"vlan"`
	SecondaryName string `json:"secondaryName"`
}

type VXCOrder

type VXCOrder struct {
	AssociatedVXCs []VXCConfiguration `json:"associatedVxcs"`
	PortID         string             `json:"productUid"`
}

---- VXC Order Types //

type VXCOrderAEndConfiguration

type VXCOrderAEndConfiguration struct {
	VLAN int `json:"vlan"`
}

type VXCOrderBEndConfiguration

type VXCOrderBEndConfiguration struct {
	VLAN       int    `json:"vlan,omitempty"`
	ProductUID string `json:"productUid"`
}

type VXCOrderConfirmation

type VXCOrderConfirmation struct {
	TechnicalServiceUID string `json:"vxcJTechnicalServiceUid"`
}

type VXCOrderResponse

type VXCOrderResponse struct {
	Message string                 `json:"message"`
	Terms   string                 `json:"terms"`
	Data    []VXCOrderConfirmation `json:"data"`
}

type VXCResources

type VXCResources struct {
	Interface     []PortInterface        `json:"interface"`
	VirtualRouter map[string]interface{} `json:"virtual_router"`
	CspConnection interface{}            `json:"csp_connection"`
	VLL           VLLConfig              `json:"vll"`
}

type VXCResponse

type VXCResponse struct {
	Message string `json:"message"`
	Terms   string `json:"terms"`
	Data    VXC    `json:"data"`
}

type VXCUpdate

type VXCUpdate struct {
	Name      string `json:"name"`
	RateLimit int    `json:"rateLimit"`
	AEndVLAN  int    `json:"aEndVlan"`
	BEndVLAN  *int   `json:"bEndVlan,omitempty"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL