Skip to main content

PUT Modify PCR Profile

This endpoint updates the Policy and Charging Rules (PCR) profile for a specific SIM card including data, voice, SMS, and wallet configurations.

Configure the API Endpoint

Danger: Modifying a PCR profile incorrectly can lead to poor performance or service suspension. Always double-check the parameters before making a request.

https://esim.betatel.com/api/v1/esim/sim-pcr-profiles/{iccid}
  • Method: PUT

Set Up the Headers

ParamValueDescription
Content-Typeapplication/jsonSpecifies the payload format.
x-api-key{{x-api-key}}Your unique API key for secure access.
x-user-id{{x-user-id}}Your user identifier for added security and tracking.

Path Parameters

ParamTypeRequiredDescription
iccidstringrequiredThe ICCID of the SIM card

Request Body

Warning: Any mistakes in the request payload can result in failed updates. Follow the specified format carefully.

Request Body Example
{
"data": {
"state": "ENABLED",
"active_throttling": "SPEED_1000_KBPS"
},
"voice": {
"state": "ENABLED"
},
"sms": {
"state": "DISABLED"
},
"wallet_mode": "SIM",
"route_policy": 1
}

Parameters

ParamTypeRequiredDescription
data.statestringrequired when data object providedDesired state (ENABLED, DISABLED)
data.active_throttlingstringoptionalThrottling speed (NO_LIMIT, SPEED_100_KBPS, SPEED_500_KBPS, SPEED_1000_KBPS, SPEED_2000_KBPS, SPEED_3000_KBPS, SPEED_5000_KBPS)
voice.statestringrequired when voice object providedVoice service state (ENABLED, DISABLED)
sms.statestringrequired when sms object providedSMS service state (ENABLED, DISABLED)
wallet_modestringoptionalWallet usage mode (GROUP, SIM)
route_policyintegeroptionalRoute policy for network signal handling

Example Response

Status Code: 204 No Content

The PCR profile has been updated successfully. No response body is returned.

Code Snippets

Note: Use these code snippets to integrate the API calls into your system effectively. Adapt them as necessary to fit your application's needs.

Example - cURL
curl --location --request PUT 'https://esim.betatel.com/api/v1/esim/sim-pcr-profiles/{{iccid}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header 'x-api-key: {{x-api-key}}' \
--header 'x-user-id: {{x-user-id}}' \
--data '{
"data": {
"state": "ENABLED",
"active_throttling": "SPEED_1000_KBPS"
}
}'

Error Handling

Important: Pay attention to status codes. A '400' indicates invalid input, while a '401' suggests authentication problems.

  • 400 - Bad Request - Invalid input parameters or malformed request
  • 401 - Unauthorized - Authentication failure