/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 * @generated-id: 15c1e62edefa
 */

import * as z from "zod/v4";
import { safeParse } from "../../lib/schemas.js";
import { Result as SafeParseResult } from "../../types/fp.js";
import { SDKValidationError } from "../errors/sdkvalidationerror.js";

export type TempoTraceAttributeStringValue = {
  /**
   * The string value of the attribute
   */
  stringValue: string;
};

/** @internal */
export const TempoTraceAttributeStringValue$inboundSchema: z.ZodType<
  TempoTraceAttributeStringValue,
  unknown
> = z.object({
  stringValue: z.string(),
});

export function tempoTraceAttributeStringValueFromJSON(
  jsonString: string,
): SafeParseResult<TempoTraceAttributeStringValue, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => TempoTraceAttributeStringValue$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'TempoTraceAttributeStringValue' from JSON`,
  );
}
