> ## Documentation Index
> Fetch the complete documentation index at: https://docs.oneclickdz.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Send Internet Top-Up

> Purchase and send ADSL or 4G LTE internet recharge card

## Overview

Purchase internet recharge cards for ADSL or 4G LTE services with instant digital delivery.

<Note>
  Always [validate phone numbers](/en/api-reference/internet/validate-number)
  before submitting to reduce errors.
</Note>

## Request Body

<ParamField body="type" type="string" required>
  Service type: `ADSL` or `4G`
</ParamField>

<ParamField body="number" type="string" required>
  Phone number - **ADSL:** `0[0-9]{8}` (e.g., `036362608`) - **4G:** `213[0-9]   {9}` (e.g., `213472731602`)
</ParamField>

<ParamField body="value" type="number" required>
  Card denomination from `/internet/products` (e.g., 500, 1000, 2000)
</ParamField>

<ParamField body="ref" type="string">
  Your unique order reference (optional, auto-generated if not provided)
</ParamField>

## Examples

<CodeGroup>
  ```bash cURL theme={null}
  curl https://api.oneclickdz.com/v3/internet/send \
    -X POST \
    -H "Content-Type: application/json" \
    -H "X-Access-Token: YOUR_API_KEY" \
    -d '{
      "type": "ADSL",
      "number": "036362608",
      "value": 1000,
      "ref": "internet-order-001"
    }'
  ```

  ```javascript Node.js theme={null}
  const response = await fetch("https://api.oneclickdz.com/v3/internet/send", {
    method: "POST",
    headers: {
      "Content-Type": "application/json",
      "X-Access-Token": "YOUR_API_KEY",
    },
    body: JSON.stringify({
      type: "ADSL",
      number: "036362608",
      value: 1000,
      ref: "internet-order-001",
    }),
  });
  const data = await response.json();
  ```

  ```python Python theme={null}
  response = requests.post(
      'https://api.oneclickdz.com/v3/internet/send',
      headers={
          'Content-Type': 'application/json',
          'X-Access-Token': 'YOUR_API_KEY'
      },
      json={
          'type': 'ADSL',
          'number': '036362608',
          'value': 1000,
          'ref': 'internet-order-001'
      }
  )
  ```

  ```php PHP theme={null}
  <?php
  $data = [
      'type' => 'ADSL',
      'number' => '036362608',
      'value' => 1000,
      'ref' => 'internet-order-001'
  ];

  $ch = curl_init('https://api.oneclickdz.com/v3/internet/send');
  curl_setopt($ch, CURLOPT_POST, true);
  curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  curl_setopt($ch, CURLOPT_HTTPHEADER, [
      'Content-Type: application/json',
      'X-Access-Token: YOUR_API_KEY'
  ]);
  curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
  $response = json_decode(curl_exec($ch), true);
  ?>
  ```
</CodeGroup>

### Success Response

```json theme={null}
{
  "success": true,
  "data": {
    "topupId": "690161a3e9e88196b4eb6545",
    "topupRef": "API-+213665983439-test-internet-1761698210633"
  },
  "meta": {
    "timestamp": "2025-10-29T00:36:52.065Z"
  }
}
```

## Status Lifecycle

<Steps>
  <Step title="HANDLING">Processing with operator (3-45 seconds typical)</Step>

  <Step title="Final States">
    * **FULFILLED:** Card delivered ✅ - **REFUNDED:** Failed and refunded ❌ -
      **QUEUED:** Scheduled for later (12-48h) ⏰
  </Step>
</Steps>

[Track status →](/en/api-reference/internet/check-by-ref)

## Error Responses

<AccordionGroup>
  <Accordion title="ERR_VALIDATION">Invalid request parameters</Accordion>

  <Accordion title="ERR_PHONE">
    Invalid phone number format or type mismatch
  </Accordion>

  <Accordion title="ERR_STOCK">Card value out of stock</Accordion>
  <Accordion title="INSUFFICIENT_BALANCE">Not enough balance</Accordion>
  <Accordion title="DUPLICATED_REF">Reference already used</Accordion>
</AccordionGroup>

## Best Practices

<CardGroup cols={2}>
  <Card title="Validate First" icon="check">
    Use `/check-number` before submitting
  </Card>

  <Card title="Check Stock" icon="box">
    Verify product availability
  </Card>

  <Card title="Unique References" icon="fingerprint">
    Provide unique `ref` for tracking
  </Card>

  <Card title="Poll Status" icon="arrows-rotate">
    Check status after submission
  </Card>
</CardGroup>

## Related

<CardGroup cols={3}>
  <Card title="Validate Number" href="/en/api-reference/internet/validate-number">
    Check phone validity
  </Card>

  <Card title="Check Status" href="/en/api-reference/internet/check-by-ref">
    Track order
  </Card>

  <Card title="List Products" href="/en/api-reference/internet/list-products">
    Available cards
  </Card>
</CardGroup>
