Class CreateKillswitchRequest

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

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.23.0") public class CreateKillswitchRequest extends Object
Body for `POST /api/admin/killswitches`. Only `name` is required.
  • Field Details

  • Constructor Details

    • CreateKillswitchRequest

      public CreateKillswitchRequest()
  • Method Details

    • name

      public CreateKillswitchRequest name(@Nonnull String name)
    • getName

      @Nonnull public String getName()
      Stable config/killswitch key in `folder.name` form (two lowercase segments separated by a dot, e.g. `pricing.tiers`). Immutable after create.
      Returns:
      name
    • setName

      public void setName(@Nonnull String name)
    • description

      public CreateKillswitchRequest description(@Nullable String description)
    • getDescription

      @Nullable public String getDescription()
      Optional free-form description shown in the dashboard. Max 512 chars.
      Returns:
      description
    • setDescription

      public void setDescription(@Nullable String description)
    • folder

      public CreateKillswitchRequest folder(@Nullable String folder)
    • getFolder

      @Nullable public String getFolder()
      Optional folder name grouping items in the dashboard. Alphanumeric, `_` or `-` (no `/`). Part of the SDK lookup key (`<folder>/<name>`).
      Returns:
      folder
    • setFolder

      public void setFolder(@Nullable String folder)
    • value

      public CreateKillswitchRequest value(@Nullable Boolean value)
    • getValue

      @Nullable public Boolean getValue()
      Default value applied to every env at creation. Defaults to `false`. Use `true` to ship the killswitch pre-tripped.
      Returns:
      value
    • setValue

      public void setValue(@Nullable Boolean value)
    • switches

      public CreateKillswitchRequest switches(@Nullable Map<String,Boolean> switches)
    • putSwitchesItem

      public CreateKillswitchRequest putSwitchesItem(String key, Boolean switchesItem)
    • getSwitches

      @Nullable public Map<String,Boolean> getSwitches()
      Initial per-switch overrides applied to every env. Empty/omitted leaves the killswitch with only the flat `value`.
      Returns:
      switches
    • setSwitches

      public void setSwitches(@Nullable Map<String,Boolean> switches)
    • 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 CreateKillswitchRequest
    • fromJson

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

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