# `Lather.Soap.Body`
[🔗](https://github.com/awksedgreep/lather/blob/v1.0.49/lib/lather/soap/body.ex#L1)

SOAP body utilities.

Provides functionality for creating and managing SOAP body content,
including parameter serialization and response parsing.

# `create`

```elixir
@spec create(atom() | String.t(), map(), keyword()) :: map()
```

Creates a SOAP body element for the given operation and parameters.

## Parameters

* `operation` - Operation name (atom or string)
* `params` - Operation parameters (map)
* `options` - Body options

## Options

* `:namespace` - Target namespace for the operation
* `:namespace_prefix` - Prefix for the target namespace

## Examples

    iex> Body.create(:get_user, %{id: 123}, namespace: "http://example.com")
    %{
      "get_user" => %{
        "@xmlns" => "http://example.com",
        "id" => 123
      }
    }

# `serialize_params`

```elixir
@spec serialize_params(any()) :: any()
```

Serializes Elixir data structures to XML-compatible format.

Handles various Elixir types and converts them to XML-safe representations.

# `validate_params`

```elixir
@spec validate_params(map(), map()) :: :ok | {:error, [String.t()]}
```

Validates parameters against expected types and constraints.

## Parameters

* `params` - Parameters to validate
* `schema` - Validation schema (map)

## Schema Format

The schema is a map where keys are parameter names and values are validation rules:

    %{
      "id" => [:required, :integer],
      "name" => [:required, :string, {:max_length, 50}],
      "email" => [:optional, :string, :email]
    }

---

*Consult [api-reference.md](api-reference.md) for complete listing*
