Segments

Access to subscription segments


Parameters

Name In Type Required Description
org_id path string true Organization name
id path string true subscription unique identifier

Request example

1
2
3
4

curl -X GET https://subscriptions.masstack.com/v1/orgs/yoigo/subscriptions/5652763/segments \
  -H "Accept: application/json"

Responses

Code Meaning Description Schema
200 OK OK GetSubscriptionSegments
500 Internal Server Error Unexpected error ErrorMessage

Parameters

Name In Type Required Description
org_id path string true Organization name
id path string true Subscription Id
body body PostSegments true ‘none’

Request body - instance of PostSegments

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
{
  "segments": [
    {
      "segment_id": "SEGMENT_ID",
      "segment_value": "SEGMENT_VALUE",
      "change_user": "test@test.com",
      "change_reason": "customer request"
    }
  ]
}
Name Type Required Description
segments [PostSegment] true none

Request example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15

curl -X POST https://subscriptions.masstack.com/v1/orgs/masmovil/subscriptions/3821002/segments \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
 --data-raw "{
  'segments': [
    {
      'segment_id': 'SEGMENT_ID',
      'segment_value': 'SEGMENT_VALUE',
      'change_user': 'test@test.com',
      'change_reason': 'customer request'
    }
  ]
}" 

Responses

Code Meaning Description Schema
204 No Content Segments creation successfully done None
400 Bad Request Invalid body ErrorMessage
404 Not Found A subscription with the specified id was not found ErrorMessage
500 Internal Server Error Unexpected error ErrorMessage

Endpoints

AccountBundles

    Apple Watch

      Credit Limits

        Devices

          Fraud Requests

            FreeUnitsPackages

              Promotions

                Segments

                  Subscription Commercial Products

                    Subscriptions

                      Contracts