{{- if .Values.secrets.create -}}
apiVersion: v1
kind: Secret
metadata:
  name: {{ include "openclaw.fullname" . }}
  labels:
    {{- include "openclaw.labels" . | nindent 4 }}
type: Opaque
stringData:
  gatewayToken: {{ .Values.secrets.data.gatewayToken | default (randAlphaNum 32) | quote }}
  {{- with .Values.secrets.data.anthropicApiKey }}
  anthropicApiKey: {{ . | quote }}
  {{- end }}
  {{- with .Values.secrets.data.openaiApiKey }}
  openaiApiKey: {{ . | quote }}
  {{- end }}
  {{- with .Values.secrets.data.discordBotToken }}
  discordBotToken: {{ . | quote }}
  {{- end }}
  {{- with .Values.secrets.data.telegramBotToken }}
  telegramBotToken: {{ . | quote }}
  {{- end }}
{{- end }}
