POST /v1/links

Create your short links with this service, use all the fields that you want to increase the analytics and tracking

multipart/form-data

Body Required

  • campaign_name string

    enter a campaign name

    Default value is smart bear.

  • client_id string Required

    Client id from the h2o service customer

    Default value is 28Eyd2p2ofdVapXLDXNnzjTL2vC2.

  • custom_domain string

    enter a custom domain

    Default value is h2o.ac.

  • metadata string

    enter some metada json

    Default value is {}.

  • sec_id string

    enter a secondary link id

    Default value is 0928374.

  • url string Required

    URL to be encoded

    Default value is https://ecx-labs.com.

Responses

  • 200 application/json
    Hide response attributes Show response attributes object
    • error string
    • result string
  • 400 application/json
    Hide response attributes Show response attributes object
    • error string
    • result string
  • default
POST /v1/links
curl \
 -X POST https://api.h2olinks.com/v1/links \
 -H "X-API-Key: $API_KEY" \
 -H "Content-Type: multipart/form-data" \
 -F "campaign_name=smart bear" \
 -F "client_id=28Eyd2p2ofdVapXLDXNnzjTL2vC2" \
 -F "custom_domain=h2o.ac" \
 -F "metadata={}" \
 -F "sec_id=0928374" \
 -F "url=https://ecx-labs.com"
Response examples (200)
{
  "error": "string",
  "result": "string"
}
Response examples (400)
{
  "error": "string",
  "result": "string"
}