Add IP to IP Allowlist

JFrog REST APIs

ft:sourceType
Paligo

Description: Adds an IP or list of IPs to the JPD allowlist.

Since: January 25, 2023

Security: Requires a valid tokenGenerate a Token in MyJFrog

Usage: POST api/v1/allowlist/{serverName}

Content-Type: application/json

Produces: application/json

Sample Usage:

curl --location --request POST 'https://my.jfrog.com/api/jmis/v1/allowlist/{serverName} \
--header 'Authorization: Bearer ' \
--header 'Content-Type: application/json' \
--data-raw '{
"ips": [
        "2.2.2.7/1",
        "1.1.1.7/1"
]
}'

Sample Response:

{
    "status": "IN_PROGRESS",
    "message": "Success, the action will take a few minutes to complete",
    "errors": [
        {
            "message": "Existing IPs",
            "details": [
                "2.2.2.7/1",
                "1.1.1.7/1"
            ]
        },
        {
            "message": "Invalid IPs",
            "details": [
                "text"
            ]
        }
    ]
}

Response status codes:

200- Success

400- Failed

409- Another IP action is in progress (try again in a few minutes)

403- Server Blocked / Valid token does not match the server name

401- Unauthorized user

429- Too many requests