> For the complete documentation index, see [llms.txt](https://pavan-joshi.gitbook.io/making-payment-transactions-smart/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pavan-joshi.gitbook.io/making-payment-transactions-smart/working-architecture-of-spec/structure-and-pass-metadata.md).

# 󠁻󠁻Structure and Pass Metadata

Step Two - Structure and Pass Metadata

### Structure Metadata

This specification uses data models derived from standards such as [schema.org](https://schema.org) to deliver structure to metadata and define some standard properties, which we use to describe metadata.

[**Schema.org**](http://schema.org) allows the structuring of data using **JSON-LD** format. **JSON-LD** is a **JSON** having an additional *`@context`* field. We use the same schema to structure metadata without the presence of this field.

Each data model possesses a type with the various supported attributes which a lightning web application can utilise to structure metadata. Data model types such as ***AudioObject, ImageObject, VideoObject*** and many more are present to structure metadat&#x61;***.***

Use our data models of the suitable type to structure metadata in **JSON** forma&#x74;**:**

{% content-ref url="/pages/HCoAL7FxjM7TXIv661zi" %}
[Data Model Overview](/making-payment-transactions-smart/data-models/data-model-overview.md)
{% endcontent-ref %}

Eg.

```
let metadata: {};
metadata = {
 "type": "AudioObject",
 "name": "title",
 "creator": "artist",
 "image": "image" 
 }
```

To learn more about how to structure metadata for Bitcoin transactions :

{% content-ref url="/pages/OqfvCUsiXhlDIq43s9xS" %}
[Structure Metadata Using Data Models](/making-payment-transactions-smart/data-models/structure-metadata-using-data-models.md)
{% endcontent-ref %}

### Pass Metadata

Using `SendPayment` method, the lightning web application passes an invoice along with additional metadata. WebLN provider delivers such data to the wallets.\
\
Before passing metadata to the wallet using the `SendPayment` method, metadata shall present in a structured form using the data models provided in a comprehensive guide.

```
webln.sendPayment(invoice, metadata);
```
