Class UpsertProjectRequest

java.lang.Object
ai.shipeasy.admin.model.UpsertProjectRequest

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.23.0") public class UpsertProjectRequest extends Object
Body for `POST /api/admin/projects/upsert`. Only `domain` is required; the owner is resolved from the caller's session.
  • Field Details

  • Constructor Details

    • UpsertProjectRequest

      public UpsertProjectRequest()
  • Method Details

    • domain

      public UpsertProjectRequest domain(@Nonnull String domain)
    • getDomain

      @Nonnull public String getDomain()
      Lowercase bare hostname (e.g. `acme.com`, `app.acme.com`, `*.acme.com`), or `*` to allow any origin. Full URLs with `https://` are not accepted. The project is keyed by `(owner_email, domain)`, so a second call with the same domain returns the existing project.
      Returns:
      domain
    • setDomain

      public void setDomain(@Nonnull String domain)
    • name

      public UpsertProjectRequest name(@Nullable String name)
    • getName

      @Nullable public String getName()
      Human-readable project name. Defaults to the domain on first create.
      Returns:
      name
    • setName

      public void setName(@Nullable String name)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • validateJsonElement

      public static void validateJsonElement(com.google.gson.JsonElement jsonElement) throws IOException
      Validates the JSON Element and throws an exception if issues found
      Parameters:
      jsonElement - JSON Element
      Throws:
      IOException - if the JSON Element is invalid with respect to UpsertProjectRequest
    • fromJson

      public static UpsertProjectRequest fromJson(String jsonString) throws IOException
      Create an instance of UpsertProjectRequest given an JSON string
      Parameters:
      jsonString - JSON string
      Returns:
      An instance of UpsertProjectRequest
      Throws:
      IOException - if the JSON string is invalid with respect to UpsertProjectRequest
    • toJson

      public String toJson()
      Convert an instance of UpsertProjectRequest to an JSON string
      Returns:
      JSON string