func (s *UpstreamsService) Delete(upstream string) (*http.Response, error) {
	u := fmt.Sprintf("upstreams/%v", upstream)
	req, err := s.client.NewRequest("DELETE", u, nil)
	if err != nil {
		return nil, err
	}
	resp, err := s.client.Do(req, nil)
	if err != nil {
		return resp, err
	}
	return resp, err
}
Delete deletes a single Kong upstream object, by name or id.

Equivalent to DELETE /upstreams/{name or id}
package kong
import (
	"errors"
	"fmt"
	"net/http"
)
type UpstreamsService struct {
	*service
}
type Upstreams struct {
	Data   []*Upstream `json:"data,omitempty"`
	Total  int         `json:"total,omitempty"`
	Next   string      `json:"next,omitempty"`
	Offset string      `json:"offset,omitempty"`
}
type Upstream struct {
	Name      string `json:"name"`
	ID        string `json:"id,omitempty"`
	CreatedAt int64  `json:"created_at,omitempty"`
	Slots     int    `json:"slots,omitempty"`
	Orderlist []int  `json:"orderliste,omitempty"`
}
func (s *UpstreamsService) Get(upstream string) (*Upstream, *http.Response, error) {
	u := fmt.Sprintf("upstreams/%v", upstream)
	req, err := s.client.NewRequest("GET", u, nil)
	if err != nil {
		return nil, nil, err
	}
	uResp := new(Upstream)
	resp, err := s.client.Do(req, uResp)
	if err != nil {
		return nil, resp, err
	}
	return uResp, resp, err
}
func (s *UpstreamsService) Patch(upstream *Upstream) (*http.Response, error) {
	var u string
	if upstream.Name != "" {
		u = fmt.Sprintf("upstreams/%v", upstream.Name)
	} else if upstream.ID != "" {
		u = fmt.Sprintf("upstreams/%v", upstream.ID)
	} else {
		return nil, errors.New("At least one of upstream.Name or upstream.ID must be specified")
	}
	req, err := s.client.NewRequest("PATCH", u, upstream)
	if err != nil {
		return nil, err
	}
	resp, err := s.client.Do(req, nil)
	return resp, err
}