Skip to main content
GET
/
plans
/
storage
Go (SDK)
package main

import(
	"context"
	"os"
	latitudeshgosdk "github.com/latitudesh/latitudesh-go-sdk"
	"log"
)

func main() {
    ctx := context.Background()

    s := latitudeshgosdk.New(
        latitudeshgosdk.WithSecurity(os.Getenv("LATITUDESH_BEARER")),
    )

    res, err := s.Plans.ListStorage(ctx)
    if err != nil {
        log.Fatal(err)
    }
    if res.StoragePlans != nil {
        // handle response
    }
}
{
  "data": [
    {
      "id": "plan_MLGXPdWgdnNWk",
      "type": "storage_plans",
      "attributes": {
        "name": "Filesystem",
        "regions": [
          {
            "name": "United States",
            "locations": [
              "DAL"
            ],
            "pricing": {
              "USD": {
                "month": 0.12
              },
              "BRL": {
                "month": 0.68
              }
            }
          }
        ]
      }
    }
  ]
}

Authorizations

Authorization
string
header
required

Response

200 - application/vnd.api+json

Success

data
object[]
meta
object