Create a new UI segment

Creates a new UI segment for yourself or to share with others within your organization.

SecuritySecretApiKey or JWT
Request
Request Body schema: application/json

Segment resource.

data
required
object

Object that contains a schema that is used to set up the UI for the segment. This schema is built and consumed by the frontend. It includes information such as: segment name, UI settings, and so on.

scope
required
string

Controls the visibility of the segment.

Enum: Description
private

Visible only to the owner the segment.

public

Visible to all in the owner's organization.

shared

Visible to a specific group of users that are specified in the userIds field.

isStarred
boolean

Specifies whether this segment is starred by the current user. Starring a segment marks it as a favorite segment, and also adds the segment to a starred folder in the UI.

isVisible
boolean

Specifies whether the segment is visible to the current user.

userIds
Array of strings unique

List of user IDs with which the segment is shared. This field is used when the scope field is set to shared.

systemId
string

If the segment is derived from a system segment, this field contains the ID of the related system segment. To provide this field in a request, the scope field must be set to private .

Responses
201

Segment created.

Response Headers
Location
string <uri>

Location of the related resource.

Example: "https://api.rebilly.com/example"
Response Schema: application/json
data
required
object

Object that contains a schema that is used to set up the UI for the segment. This schema is built and consumed by the frontend. It includes information such as: segment name, UI settings, and so on.

required
object

Creator of segment.

id
string <= 50 characters

User ID of the creator.

name
string

First and last name of the creator.

scope
required
string

Controls the visibility of the segment.

Enum: Description
private

Visible only to the owner the segment.

public

Visible to all in the owner's organization.

shared

Visible to a specific group of users that are specified in the userIds field.

id
string <= 50 characters

ID of the segment.

isStarred
boolean

Specifies whether this segment is starred by the current user. Starring a segment marks it as a favorite segment, and also adds the segment to a starred folder in the UI.

isVisible
boolean

Specifies whether the segment is visible to the current user.

Array of objects unique

List of user details with which this segment is shared.

Array
id
string <= 50 characters

User ID.

name
string

First and last name.

403

Access forbidden.

422

Invalid data sent.

post/grid-segments
Request samples
application/json
{
  • "data": { },
  • "isStarred": true,
  • "isVisible": true,
  • "userIds": [
    ],
  • "scope": "private",
  • "systemId": "string"
}
Response samples
application/json
{
  • "id": "4f6cf35x-2c4y-483z-a0a9-158621f77a21",
  • "owner": {
    },
  • "data": { },
  • "isStarred": true,
  • "isVisible": true,
  • "users": [
    ],
  • "scope": "private"
}