> For the complete documentation index, see [llms.txt](https://docs.goplugin.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.goplugin.co/plugin-1.0-deprecated/deployment.md).

# Deployment

Using the Oracle contract, you can use your own node to fulfill requests. This guide will show you how to deploy your own Oracle contract and add jobs to your node so that it can provide data to smart contracts.

### Requirements <a href="#requirements" id="requirements"></a>

Before you begin this guide, complete the following tasks to make sure you have all of the tools that you need:

* Set up XDCPay and obtain Apothem(Testnet) PLI.
* Configure a Xinfin client with an active WebSocket connection.&#x20;
* Run a Plugin Node and connect it to a supported database.
* Fund the XDC Wallet address that your Plugin node uses. You can find the address in the node Operator GUI under the **Keys** tab. The address of the node is the `Regular` type. You can obtain test ETH from several faucets.

### Address Types <a href="#address-types" id="address-types"></a>

Your node works with several different types of addresses. Each address type has a specific function:

* **Node address:** This is the address for your Plugin node wallet. The node requires native blockchain tokens at all times to respond to requests. For this example, the node uses XDC. When you start a Plugin node, it automatically generates this address. You can find this address on the Node Operator GUI under Keys > Account addresses.
* **Oracle contract address:** This is the address for contracts like `Operator.sol` or `Oracle.sol` that are deployed to a blockchain. Do not fund these addresses with native blockchain tokens such as XDC. When you make API call requests, the funds pass through this contract to interact with your Plugin node. This will be the address that smart contract developers point to when they choose a node for an API call.
* **Admin wallet address:** This is the address that owns your `Operator.sol` or `Oracle.sol` contract addresses. If you're on OCR, this is the wallet address that receives PLI tokens.

### Deploy your own Oracle contract <a href="#deploy-your-own-oracle-contract" id="deploy-your-own-oracle-contract"></a>

1. Go to Remix and open the `Oracle.sol` smart contract. The contents of this file will be very minimal.

```
pragma solidity 0.4.24;
import "@goplugin/contracts/src/v0.4/Oracle.sol";
```

1. On the **Compile** tab, click the **Compile** button for `Oracle.sol`. Remix automatically selects the compiler version and language from the `pragma` line unless you select a specific version manually.
2. &#x20;On the **Deploy and Run** tab, configure the following settings:
   * Select "Injected Web3" as your **Environment**. The JavaScript VM environment cannot access your oracle node.
   * Select the "Oracle" contract from the **Contract** menu.
   * Copy the PLI token contract address for the network(like Mainnet, Apothem as given below)  you are using and paste it into the `address_link` field next to the **Deploy** button:

{% tabs %}
{% tab title="Mainnet" %}
xdcff7412ea7c8445c46a8254dfb557ac1e48094391
{% endtab %}

{% tab title="Apothem" %}
xdc33f4212b027e22af7e6ba21fc572843c0d701cd1
{% endtab %}
{% endtabs %}

![](/files/KqcizReiYZyBa2cxvh8h)

Compile the program and you should see "green tick"&#x20;

Click **Deploy**. XDCPay prompts you to confirm the transaction.

![](/files/Q7i1wUUNtNbQm9iNC2WO)<br>

If the transaction is successful, a new address displays in the **Deployed Contracts** section. Keep a note of the Oracle contract address(let's remember this address as **OCA** to refer to). You need it later for your contract consumption.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.goplugin.co/plugin-1.0-deprecated/deployment.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
