Skip to content

Handle allOf types more gracefully #67

@karencfv

Description

@karencfv

Currently as the OpenAPI spec we use treats allOf types as enums, so they are being handled that way. Ideally it'd be best to treat them as allOf types.

Update: After #78 these values are treated as interfaces. This way you can pass whichever
of the struct types you need like this:

ipRange := oxide.Ipv4Range{
	First: "172.20.15.240",
	Last:  "172.20.15.250",
}

body := oxide.IpRange(ipRange)
resp, _ := client.IpPoolRangeAdd("mypool", &body)

Probably not the best approach, but will leave them this way until I come up with
a more idiomatic solution. Keep an eye out on this one to refine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions