> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.greenlane.ai/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.greenlane.ai/_mcp/server.

# Register Site

POST https://pos.fuel.greenlane.ai/gfp/register_site
Content-Type: application/json

The `register_site` API allows for registering a new merchant site, or updating an existing one (for example phone number, address, etc). The site_id should stay stable in the update case. There is no limit or side effects to calling `register_site` once, periodically, or ad-hoc for a particular location.

**Note:** Partial updates are not supported. When updating an existing site, pass in all the attributes if there is no change in them.

Reference: https://docs.greenlane.ai/greenlane-fuel-platform/register-site

## Authentication

- `Authorization` header (bearer token, required)

## Request

### Body (application/json)

- `merchant_id` (string, required)
- `merchant_name` (string, required)
- `site_id` (string, required)
- `site_name` (string, required)
- `latitude` (double, required)
- `longitude` (double, required)
- `address_street` (string, required)
- `address_city` (string, required)
- `address_state_code` (string, required)
- `address_postal_code` (string, required)
- `phone_number` (string, required)
- `operating_hours` (list of object, required)
  - `days` (string, required)
  - `hours` (string, required)
- `truck_lanes` (integer, required)
- `tz_info` (string, required)
- `hiflow_diesel_pumps` (integer, required)
- `parking_spots` (integer, required)
- `pay_inside` (boolean, required)
- `pay_outside` (boolean, required)
- `fuel_products` (list of string, required)
- `amenities` (list of string, required)
- `restaurants` (list of string, required)
- `status` (string, required)

## Response

### 200

OK

- `merchant_id` (string, required)
- `merchant_name` (string, required)
- `site_id` (string, required)
- `site_name` (string, required)
- `latitude` (double, required)
- `longitude` (double, required)
- `address_street` (string, required)
- `address_city` (string, required)
- `address_state_code` (string, required)
- `address_postal_code` (string, required)
- `phone_number` (string, required)
- `operating_hours` (list of object, required)
  - `days` (string, required)
  - `hours` (string, required)
- `truck_lanes` (integer, required)
- `tz_info` (string, required)
- `hiflow_diesel_pumps` (integer, required)
- `parking_spots` (integer, required)
- `pay_inside` (boolean, required)
- `pay_outside` (boolean, required)
- `fuel_products` (list of string, required)
- `amenities` (list of string, required)
- `restaurants` (list of string, required)
- `status` (string, required)

## Examples

**Request**

```json
{
  "merchant_id": "merchant-id",
  "merchant_name": "Abc's",
  "site_id": "331",
  "site_name": "Abc's #331",
  "latitude": 12.1234,
  "longitude": 12.1234,
  "address_street": "123 Main",
  "address_city": "Loxley",
  "address_state_code": "AL",
  "address_postal_code": "12345",
  "phone_number": "+18001234567",
  "operating_hours": [
    {
      "days": "Mon-Fri",
      "hours": "0-24"
    },
    {
      "days": "Sat-Sun",
      "hours": "8-24"
    }
  ],
  "truck_lanes": 10,
  "tz_info": "America/Los_Angeles",
  "hiflow_diesel_pumps": 10,
  "parking_spots": 54,
  "pay_inside": true,
  "pay_outside": true,
  "fuel_products": [
    "DEF",
    "DIESEL_ULSD",
    "REEFER"
  ],
  "amenities": [
    "Wi-Fi",
    "Weigh Scales",
    "Laundry Room",
    "ATM",
    "Showers",
    "Parking"
  ],
  "restaurants": [
    "Wendy's"
  ],
  "status": "ONLINE"
}
```

**Response**

```json
{
  "merchant_id": "merchant-id",
  "merchant_name": "Abc's",
  "site_id": "331",
  "site_name": "Abc's #331",
  "latitude": 12.1234,
  "longitude": 12.1234,
  "address_street": "123 Main",
  "address_city": "Loxley",
  "address_state_code": "AL",
  "address_postal_code": "12345",
  "phone_number": "+18001234567",
  "operating_hours": [
    {
      "days": "Mon-Fri",
      "hours": "0-24"
    },
    {
      "days": "Sat",
      "hours": "8-24"
    },
    {
      "days": "Sun",
      "hours": "8-20"
    }
  ],
  "truck_lanes": 10,
  "tz_info": "America/Los_Angeles",
  "hiflow_diesel_pumps": 10,
  "parking_spots": 54,
  "pay_inside": true,
  "pay_outside": true,
  "fuel_products": [
    "DEF",
    "DIESEL_ULSD",
    "REEFER"
  ],
  "amenities": [
    "Wi-Fi",
    "Weigh Scales",
    "Laundry Room",
    "ATM",
    "Showers",
    "Parking"
  ],
  "restaurants": [
    "Wendy's"
  ],
  "status": "ONLINE"
}
```

**SDK Code**

```python Register Site_example
import requests

url = "https://pos.fuel.greenlane.ai/gfp/register_site"

payload = {
    "merchant_id": "merchant-id",
    "merchant_name": "Abc's",
    "site_id": "331",
    "site_name": "Abc's #331",
    "latitude": 12.1234,
    "longitude": 12.1234,
    "address_street": "123 Main",
    "address_city": "Loxley",
    "address_state_code": "AL",
    "address_postal_code": "12345",
    "phone_number": "+18001234567",
    "operating_hours": [
        {
            "days": "Mon-Fri",
            "hours": "0-24"
        },
        {
            "days": "Sat-Sun",
            "hours": "8-24"
        }
    ],
    "truck_lanes": 10,
    "tz_info": "America/Los_Angeles",
    "hiflow_diesel_pumps": 10,
    "parking_spots": 54,
    "pay_inside": True,
    "pay_outside": True,
    "fuel_products": ["DEF", "DIESEL_ULSD", "REEFER"],
    "amenities": ["Wi-Fi", "Weigh Scales", "Laundry Room", "ATM", "Showers", "Parking"],
    "restaurants": ["Wendy's"],
    "status": "ONLINE"
}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript Register Site_example
const url = 'https://pos.fuel.greenlane.ai/gfp/register_site';
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{"merchant_id":"merchant-id","merchant_name":"Abc\'s","site_id":"331","site_name":"Abc\'s #331","latitude":12.1234,"longitude":12.1234,"address_street":"123 Main","address_city":"Loxley","address_state_code":"AL","address_postal_code":"12345","phone_number":"+18001234567","operating_hours":[{"days":"Mon-Fri","hours":"0-24"},{"days":"Sat-Sun","hours":"8-24"}],"truck_lanes":10,"tz_info":"America/Los_Angeles","hiflow_diesel_pumps":10,"parking_spots":54,"pay_inside":true,"pay_outside":true,"fuel_products":["DEF","DIESEL_ULSD","REEFER"],"amenities":["Wi-Fi","Weigh Scales","Laundry Room","ATM","Showers","Parking"],"restaurants":["Wendy\'s"],"status":"ONLINE"}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Register Site_example
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://pos.fuel.greenlane.ai/gfp/register_site"

	payload := strings.NewReader("{\n  \"merchant_id\": \"merchant-id\",\n  \"merchant_name\": \"Abc's\",\n  \"site_id\": \"331\",\n  \"site_name\": \"Abc's #331\",\n  \"latitude\": 12.1234,\n  \"longitude\": 12.1234,\n  \"address_street\": \"123 Main\",\n  \"address_city\": \"Loxley\",\n  \"address_state_code\": \"AL\",\n  \"address_postal_code\": \"12345\",\n  \"phone_number\": \"+18001234567\",\n  \"operating_hours\": [\n    {\n      \"days\": \"Mon-Fri\",\n      \"hours\": \"0-24\"\n    },\n    {\n      \"days\": \"Sat-Sun\",\n      \"hours\": \"8-24\"\n    }\n  ],\n  \"truck_lanes\": 10,\n  \"tz_info\": \"America/Los_Angeles\",\n  \"hiflow_diesel_pumps\": 10,\n  \"parking_spots\": 54,\n  \"pay_inside\": true,\n  \"pay_outside\": true,\n  \"fuel_products\": [\n    \"DEF\",\n    \"DIESEL_ULSD\",\n    \"REEFER\"\n  ],\n  \"amenities\": [\n    \"Wi-Fi\",\n    \"Weigh Scales\",\n    \"Laundry Room\",\n    \"ATM\",\n    \"Showers\",\n    \"Parking\"\n  ],\n  \"restaurants\": [\n    \"Wendy's\"\n  ],\n  \"status\": \"ONLINE\"\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Register Site_example
require 'uri'
require 'net/http'

url = URI("https://pos.fuel.greenlane.ai/gfp/register_site")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"merchant_id\": \"merchant-id\",\n  \"merchant_name\": \"Abc's\",\n  \"site_id\": \"331\",\n  \"site_name\": \"Abc's #331\",\n  \"latitude\": 12.1234,\n  \"longitude\": 12.1234,\n  \"address_street\": \"123 Main\",\n  \"address_city\": \"Loxley\",\n  \"address_state_code\": \"AL\",\n  \"address_postal_code\": \"12345\",\n  \"phone_number\": \"+18001234567\",\n  \"operating_hours\": [\n    {\n      \"days\": \"Mon-Fri\",\n      \"hours\": \"0-24\"\n    },\n    {\n      \"days\": \"Sat-Sun\",\n      \"hours\": \"8-24\"\n    }\n  ],\n  \"truck_lanes\": 10,\n  \"tz_info\": \"America/Los_Angeles\",\n  \"hiflow_diesel_pumps\": 10,\n  \"parking_spots\": 54,\n  \"pay_inside\": true,\n  \"pay_outside\": true,\n  \"fuel_products\": [\n    \"DEF\",\n    \"DIESEL_ULSD\",\n    \"REEFER\"\n  ],\n  \"amenities\": [\n    \"Wi-Fi\",\n    \"Weigh Scales\",\n    \"Laundry Room\",\n    \"ATM\",\n    \"Showers\",\n    \"Parking\"\n  ],\n  \"restaurants\": [\n    \"Wendy's\"\n  ],\n  \"status\": \"ONLINE\"\n}"

response = http.request(request)
puts response.read_body
```

```java Register Site_example
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://pos.fuel.greenlane.ai/gfp/register_site")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"merchant_id\": \"merchant-id\",\n  \"merchant_name\": \"Abc's\",\n  \"site_id\": \"331\",\n  \"site_name\": \"Abc's #331\",\n  \"latitude\": 12.1234,\n  \"longitude\": 12.1234,\n  \"address_street\": \"123 Main\",\n  \"address_city\": \"Loxley\",\n  \"address_state_code\": \"AL\",\n  \"address_postal_code\": \"12345\",\n  \"phone_number\": \"+18001234567\",\n  \"operating_hours\": [\n    {\n      \"days\": \"Mon-Fri\",\n      \"hours\": \"0-24\"\n    },\n    {\n      \"days\": \"Sat-Sun\",\n      \"hours\": \"8-24\"\n    }\n  ],\n  \"truck_lanes\": 10,\n  \"tz_info\": \"America/Los_Angeles\",\n  \"hiflow_diesel_pumps\": 10,\n  \"parking_spots\": 54,\n  \"pay_inside\": true,\n  \"pay_outside\": true,\n  \"fuel_products\": [\n    \"DEF\",\n    \"DIESEL_ULSD\",\n    \"REEFER\"\n  ],\n  \"amenities\": [\n    \"Wi-Fi\",\n    \"Weigh Scales\",\n    \"Laundry Room\",\n    \"ATM\",\n    \"Showers\",\n    \"Parking\"\n  ],\n  \"restaurants\": [\n    \"Wendy's\"\n  ],\n  \"status\": \"ONLINE\"\n}")
  .asString();
```

```php Register Site_example
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://pos.fuel.greenlane.ai/gfp/register_site', [
  'body' => '{
  "merchant_id": "merchant-id",
  "merchant_name": "Abc\'s",
  "site_id": "331",
  "site_name": "Abc\'s #331",
  "latitude": 12.1234,
  "longitude": 12.1234,
  "address_street": "123 Main",
  "address_city": "Loxley",
  "address_state_code": "AL",
  "address_postal_code": "12345",
  "phone_number": "+18001234567",
  "operating_hours": [
    {
      "days": "Mon-Fri",
      "hours": "0-24"
    },
    {
      "days": "Sat-Sun",
      "hours": "8-24"
    }
  ],
  "truck_lanes": 10,
  "tz_info": "America/Los_Angeles",
  "hiflow_diesel_pumps": 10,
  "parking_spots": 54,
  "pay_inside": true,
  "pay_outside": true,
  "fuel_products": [
    "DEF",
    "DIESEL_ULSD",
    "REEFER"
  ],
  "amenities": [
    "Wi-Fi",
    "Weigh Scales",
    "Laundry Room",
    "ATM",
    "Showers",
    "Parking"
  ],
  "restaurants": [
    "Wendy\'s"
  ],
  "status": "ONLINE"
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Register Site_example
using RestSharp;

var client = new RestClient("https://pos.fuel.greenlane.ai/gfp/register_site");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"merchant_id\": \"merchant-id\",\n  \"merchant_name\": \"Abc's\",\n  \"site_id\": \"331\",\n  \"site_name\": \"Abc's #331\",\n  \"latitude\": 12.1234,\n  \"longitude\": 12.1234,\n  \"address_street\": \"123 Main\",\n  \"address_city\": \"Loxley\",\n  \"address_state_code\": \"AL\",\n  \"address_postal_code\": \"12345\",\n  \"phone_number\": \"+18001234567\",\n  \"operating_hours\": [\n    {\n      \"days\": \"Mon-Fri\",\n      \"hours\": \"0-24\"\n    },\n    {\n      \"days\": \"Sat-Sun\",\n      \"hours\": \"8-24\"\n    }\n  ],\n  \"truck_lanes\": 10,\n  \"tz_info\": \"America/Los_Angeles\",\n  \"hiflow_diesel_pumps\": 10,\n  \"parking_spots\": 54,\n  \"pay_inside\": true,\n  \"pay_outside\": true,\n  \"fuel_products\": [\n    \"DEF\",\n    \"DIESEL_ULSD\",\n    \"REEFER\"\n  ],\n  \"amenities\": [\n    \"Wi-Fi\",\n    \"Weigh Scales\",\n    \"Laundry Room\",\n    \"ATM\",\n    \"Showers\",\n    \"Parking\"\n  ],\n  \"restaurants\": [\n    \"Wendy's\"\n  ],\n  \"status\": \"ONLINE\"\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Register Site_example
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "merchant_id": "merchant-id",
  "merchant_name": "Abc's",
  "site_id": "331",
  "site_name": "Abc's #331",
  "latitude": 12.1234,
  "longitude": 12.1234,
  "address_street": "123 Main",
  "address_city": "Loxley",
  "address_state_code": "AL",
  "address_postal_code": "12345",
  "phone_number": "+18001234567",
  "operating_hours": [
    [
      "days": "Mon-Fri",
      "hours": "0-24"
    ],
    [
      "days": "Sat-Sun",
      "hours": "8-24"
    ]
  ],
  "truck_lanes": 10,
  "tz_info": "America/Los_Angeles",
  "hiflow_diesel_pumps": 10,
  "parking_spots": 54,
  "pay_inside": true,
  "pay_outside": true,
  "fuel_products": ["DEF", "DIESEL_ULSD", "REEFER"],
  "amenities": ["Wi-Fi", "Weigh Scales", "Laundry Room", "ATM", "Showers", "Parking"],
  "restaurants": ["Wendy's"],
  "status": "ONLINE"
] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://pos.fuel.greenlane.ai/gfp/register_site")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```