Skip to main content

GlobalProtect Agent Profiles (Application Settings) Configuration Object

Manages GlobalProtect agent profiles in Palo Alto Networks Strata Cloud Manager. Agent profiles control the GlobalProtect app behavior for mobile users: agent UI options, authentication overrides, gateways, app configuration (connect method, tunnel MTU), HIP collection, and more.

note

The Strata Cloud Manager UI refers to this resource as App Settings / Application Settings (under Workflows → GlobalProtect App). The underlying API resource is agent-profiles.

Class Overview

The AgentProfiles class inherits from BaseObject and provides CRUD operations for GlobalProtect agent profile objects.

Unlike most SDK resources, the agent-profiles API exposes no /{id} paths: objects are addressed by name within the Mobile Users folder. Updates are sent to the collection endpoint and deletes are performed by name.

Methods

MethodDescriptionParametersReturn Type
create()Creates a new agent profiledata: Dict[str, Any]AgentProfilesResponseModel
update()Updates an existing profile by namedata: Dict[str, Any]Optional[AgentProfilesResponseModel]
delete()Deletes an agent profile by namename: str, folder: strNone
list()Lists profiles with filteringfolder: str, name: Optional[str], **filtersList[AgentProfilesResponseModel]
fetch()Gets a profile by name and foldername: str, folder: strAgentProfilesResponseModel
note

update() returns None when the API responds with 200 OK and no body (the documented behavior); use fetch() afterwards if you need the updated object.

Model Attributes

AttributeTypeRequiredDescription
namestrYesName of the agent profile
folderstrYes*Must be "Mobile Users" for all operations
agent_uiAgentUINoAgent UI options (passcode, overrides, welcome page)
authentication_overrideAuthenticationOverrideNoAuthentication override cookie settings
certificateAgentProfileCertificateNoCertificate profile matching criteria
client_certificateClientCertificateNoLocal or SCEP client certificate
custom_checksCustomChecksNoCustom plist/registry matching criteria
gatewaysGatewaysNoExternal and internal gateway configuration
gp_app_configGPAppConfigNoApp config (connect-method, tunnel-mtu)
hip_collectionHipCollectionNoHIP data collection settings
internal_host_detectionInternalHostDetectionNoInternal host detection (IPv4)
internal_host_detection_v6InternalHostDetectionV6NoInternal host detection (IPv6)
machine_account_exists_with_serialnoMachineAccountExistsWithSerialnoNoMachine account exists with serial number setting
osList[AgentProfileOperatingSystem]NoOperating systems the profile applies to
save_user_credentialsSaveUserCredentialsNoSave user credentials behavior ("0"–"3")
source_userList[str]NoSource users the profile applies to
third_party_vpn_clientsList[ThirdPartyVpnClient]NoSupported third party VPN clients

* Required for create and update operations (sent as a query parameter)

Exceptions

ExceptionHTTP CodeDescription
InvalidObjectError400Invalid profile data or folder value
MissingQueryParameterError400Missing required parameters
ObjectNotPresentError404Agent profile not found
AuthenticationError401Authentication failed
ServerError500Internal server error

Basic Configuration

from scm.client import Scm

client = Scm(
client_id="your_client_id",
client_secret="your_client_secret",
tsg_id="your_tsg_id"
)

agent_profiles = client.agent_profile

Methods

List Agent Profiles

profiles = client.agent_profile.list(folder="Mobile Users")

for profile in profiles:
print(f"{profile.name}: os={profile.os}")

Fetch an Agent Profile

profile = client.agent_profile.fetch(name="windows-profile", folder="Mobile Users")
print(profile.model_dump(exclude_unset=True))

Create an Agent Profile

profile_data = {
"name": "windows-profile",
"folder": "Mobile Users",
"os": ["Windows"],
"source_user": ["any"],
"agent_ui": {
"agent_user_override_timeout": 30,
"max_agent_user_overrides": 5,
"passcode": "secret-passcode",
},
"gp_app_config": {
"config": [
{"name": "connect-method", "value": ["user-logon"]},
{"name": "tunnel-mtu", "value": [1400]},
]
},
"gateways": {
"external": {
"list": [
{
"name": "us-east-gateway",
"choice": {"fqdn": "gw.example.com"},
"manual": True,
"priority_rule": [{"name": "rule-1", "priority": "1"}],
}
]
}
},
}

new_profile = client.agent_profile.create(profile_data)
print(f"Created: {new_profile.name}")

Update an Agent Profile

update_data = {
"name": "windows-profile", # addressed by name, no id
"folder": "Mobile Users",
"os": ["Windows", "Mac"],
"save_user_credentials": "1",
}

result = client.agent_profile.update(update_data)
# The API returns 200 OK with no body; re-fetch if you need the updated object
updated = client.agent_profile.fetch(name="windows-profile")

Delete an Agent Profile

client.agent_profile.delete(name="windows-profile", folder="Mobile Users")