Endpoint: /sites/{siteId}/dropOffPortal

Returns and updates drop off portal configuration for specific site.

  • PATCH

  • GET

Method & URL

GET https://[server URL]:[port]/admin/v2/sites/{siteId}/dropOffPortal

GET Body Sample

Copy
## GET Drop Off Portal Settings####
GET https://{{host}}/admin/v2/sites/{{Siteid}}/dropOffPortal/ HTTP/1.1
Authorization: EFTAdminAuthToken {{AuthToken}}

GET Response Body Sample

Copy
{ "data": { "id": "df3be28b-f499-4b0a-9c53-7cee33a58161", "type": "dropOffPortal", 
"attributes": { "enabled": true, "reservedPath": "/dropoff", "captcha": { "type": "reCAPTCHA", 
"value": { "siteKey": "6LeXY8ofdsfdsfdsfasq8RdygpeBeclHqrVBUd-afar", 
"secretKey": "6LeXY8oUAAAAABIVq8RdygpeBeclHqrVBUd-afar" } }, "linkExpiration": { "value": 1, 
"units": "Week" }, "maxMessageSize": { "enabled": true, "mBytes": 2048 }, 
"sendEntireMessageSecurely": "LetUserChoose", "userEmailOption": { "allowToEnterToEmailAddress": true, 
"allowedDomains": { "enabled": true, "list": [ "*.*" ] } }, "addressBookList": [ "user2<ivan@mail.com>", 
"User1<elver@mail.com>" ] } }, "links": { "self": 
"admin/v2/sites/df3be28b-f499-4b0a-9c53-7cee33a58161/dropOffPortal" } }

GET PowerShell Sample

Copy
####Added 2/10/2022 ### 
###GET Drop Off Portal Settings###
Write-Output "GET Drop Off Portal Settings"
Write-Output "----------------------------"
#$siteID = "Enter site ID"
$DropOfflist = Invoke-RestMethod -Uri "$baseURL/v2/sites/$siteID/dropOffPortal" 
-Method 'GET' -Headers $authHeader
Write-Output $DropOfflist | ConvertTo-Json -Depth 25 

Method & URL

PATCH https://[server URL]:[port]/admin/v2/sites/{siteId}/dropOffPortal

PATCH Body Sample

Copy
### PATCH Drop Off Portal Settings###
PATCH https://{{host}}/admin/v2/sites/{{Siteid}}/dropOffPortal/ HTTP/1.1
Authorization: EFTAdminAuthToken {{AuthToken}}

{
  "data": {
    "type": "dropOffPortal",
    "attributes": {
      "enabled": true,
      "reservedPath": "/dropoff",
      "captcha": {
        "type": "reCAPTCHA",
        "value": {
          "siteKey": "6LeXY8odfasdfdsafdsafdsfsdfdsfdsfsdfdsfds-afar",
          "secretKey": "6Ldfasdfdsafdsafsdafdsafsdasfdsafdsfsd-afar"
        }
      },
      "linkExpiration": {
        "value": 1,
        "units": "Week"
      },
      "maxMessageSize": {
        "enabled": true,
        "mBytes": 2048
      },
      "sendEntireMessageSecurely": "LetUserChoose",
      "userEmailOption": {
        "allowToEnterToEmailAddress": true,
        "allowedDomains": {
          "enabled": true,
          "list": [
            "*.*"
          ]
        }
      },
      "addressBookList": ["user2<user2@mail.com>", "User1<user2r@mail.com>"] 
    }
  }
}

PATCH Response Body Sample

The response will return the same response as the GET request, however, it will now include the updated Patch request(s).

Copy
{ "data": { "id": "0de7387f-1506-427d-b997-e18bcdb8cbae", "type": "dropOffPortal", "attributes": { "enabled": true, 
"reservedPath": "/dropoff", "captcha": { "type": "reCAPTCHA", "value": { "siteKey": 
"6LeXY8oUAAAAABIVq8RdygpeBeclHqrVBUd-afar", "secretKey": "6LeXY8oUAAAAABIVq8RdygpeBeclHqrVBUd-afar" } }, 
"linkExpiration": { "value": 1, "units": "Week" }, "maxMessageSize": { "enabled": true, "mBytes": 2048 }, 
"sendEntireMessageSecurely": "LetUserChoose", "userEmailOption": { "allowToEnterToEmailAddress": true, 
"allowedDomains": { "enabled": true, "list": [ "*.*" ] } }, "addressBookList": [] } }, "links": { "self": 
"admin/v2/sites/0de7387f-1506-427d-b997-e18bcdb8cbae/dropOffPortal" } }

PATCH PowerShell Sample

Copy
Write-Output "PATCH Drop Off Portal Settings"
Write-Output "------------------------------"
$update = 
'{
  "data": {
    "type": "dropOffPortal",
    "attributes": {
      "enabled": true,
      "reservedPath": "/dropoff",
      "captcha": {
        "type": "reCAPTCHA",
        "value": {
          "siteKey": "6LeXY8odfasdfdsafdsafdsfsdfdsfdsfsdfdsfds-afar",
          "secretKey": "6Ldfasdfdsafdsafsdafdsafsdasfdsafdsfsd-afar"
        }
      },
      "linkExpiration": {
        "value": 1,
        "units": "Week"
      },
      "maxMessageSize": {
        "enabled": true,
        "mBytes": 2048
      },
      "sendEntireMessageSecurely": "LetUserChoose",
      "userEmailOption": {
        "allowToEnterToEmailAddress": true,
        "allowedDomains": {
          "enabled": true,
          "list": [
            "*.*"
          ]
        }
      },
      "addressBookList": []
    }
  }
}'
$update = $update | ConvertFrom-Json
$update = $update | ConvertTo-Json -Depth 30
$patchReturn = Invoke-RestMethod -Uri "$baseURL/v2/sites/$siteID/dropOffPortal" 
-Method 'PATCH' -Headers $authHeader -Body $update