# Class Base64Source

Namespace
  AnthropicClient.Models

Assembly
  AnthropicClient.dll

Represents a base64 source.

    public class Base64Source : Source

Inheritance
  object
  Source
  Base64Source

Derived
  DocumentSource
  ImageSource

Inherited Members
  Source.Type
  object.Equals(object)
  object.Equals(object, object)
  object.GetHashCode()
  object.GetType()
  object.MemberwiseClone()
  object.ReferenceEquals(object, object)
  object.ToString()

## Constructors

### Base64Source(string, string)

Initializes a new instance of the Base64Source class.

    public Base64Source(string mediaType, string data)

#### Parameters

`mediaType` string

  The media type of the source.

`data` string

  The data of the source.

#### Exceptions

ArgumentException

  Thrown when the media type is invalid.

ArgumentNullException

  Thrown when the media type or data is null.

## Properties

### Data

Gets the data of the source.

    public string Data { get; init; }

#### Property Value

string

### MediaType

Gets the media type of the source.

    [JsonPropertyName("media_type")]
    public string MediaType { get; init; }

#### Property Value

string