Get properties

get

/rest/ofscMetadata/v1/properties

This operation retrieves a collection of properties.

The operation returns all the translations related to the name of the properties. The response contains the translations of the property name in the user's language in the translation structure and in the entity fields.

Request

Query Parameters
  • The entity of the property.
  • The translation language code. Based on the value of this parameter, the translation for the name of the activity type is returned in the 'name' field.
    • If the value is specified, then the translated value is returned in the 'name' field and the 'translations' field is not returned in the response.
    • If translation for the specified language does not exist, then the value in the 'name' field is returned in English.
    • If the value is not specified, then the 'translations' field is returned in the response and contains the translations to every language in the system.

    For the list of supported language codes, see Supported Language Codes.

  • The number of properties to be returned in the response. The minimum value that can be specified is 1 and the maximum value that can be specified is 100. If the specified value is greater than 100, zero, or if no value is specified, then it defaults to 100.
  • The number of items that are skipped in the response. If a value is not specified, then it defaults to zero. The value zero indicates that the retrieval starts from the beginning of the collection.
  • The type of the property.
Back to Top

Response

Supported Media Types

200 Response

This section describes the 200 status response for this operation.
Body ()
Root Schema : PropertiesGet
Type: object
The collection of properties.
Show Source
Nested Schema : items
Type: array
Show Source
Nested Schema : Property
Type: object
Title: Property
Show Source
  • Title: Allow Draw
    Contains one of the following values: true or false. If true, then the user can draw on the captured image using a stylus. If false, then the user cannot draw on the captured image using a stylus.

    This field is optional and is present only for the file properties that have the GUI Image element.

  • Title: Fusion Attachment Category

    A label of the Fusion Attachment Category. This attribute is applicable for properties of type 'attachments' with a Fusion configured storage.
    Maximum Length: 30

  • Title: Fusion Business Object

    A business object type (Service Work Order or Maintenance Work Order) to which the attachment is related. Allowed values : [ serviceWorkOrder, maintenanceWorkOrder ]. This attribute is applicable for properties of type 'attachments' with a Fusion configured storage.

  • Title: Clone Flag
    Contains one of the following values: true or false. If true, then the property is duplicated while reopening an activity or applying pre-work for a new activity. If false, then you cannot duplicate the property.

    This field is optional and present for all the property types except 'field'. It is not set for the entity 'resource'.

  • Title: Entity
    Allowed Values: [ "activity", "inventory", "resource", "service request", "user" ]
    The entity of the property.

    This field is present for all property types. It is required in a PUT operation and is optional in a PATCH operation. This field cannot be changed for an existing property.

  • Title: File Size Limit
    Allowed Values: [ "0.5MB", "1MB", "2MB", "3MB", "5MB" ]
    The maximum file size allowed for 'file' elements. The default and the maximum size allowed is 5 MB.

    This field is optional and is present only for the file properties with the GUI file element.

  • Title: Get Geolocation
    Contains one of the following values: true or false. If true, then the location information is saved on the map. If false, then the location information is not saved on the map.

    This field is optional and is present only for the file properties with the GUI image element.

  • Title: GUI
    Allowed Values: [ "text", "checkbox", "combobox", "radiogroup", "file", "signature", "image", "url", "phone", "email", "capture", "geo", "attachments" ]
    The GUI of the property. It defines how the property is displayed to the users.

    This field is present for all property types. It is required in a PUT operation and optional in a PATCH operation. It cannot be changed for a property of type 'field'.

  • Title: Hint
    The hint of the property name in the user's language.

    This field is present for all the types of properties. It is returned only by using a GET operation and is ignored in PUT and PATCH operations.

  • Title: Label
    Minimum Length: 1
    Maximum Length: 40
    The label of the property. It is the unique identifier of the property in Oracle Field Service.

    This field is present for all the types of properties. The label cannot be changed for an existing property.

  • Title: Lines
    Minimum Value: 1
    Maximum Value: 9
    The number of lines that the property displays in the Activity Details form.

    This field is optional and is present only for the properties of type 'string'. The value can be set only to 1 for all GUI elements except for the 'text' element.

  • Title: Max Height
    Minimum Value: 10
    Maximum Value: 5000
    The maximum height of the property. This field is optional and is present only for the file properties with the GUI image element.
  • Title: Max Width
    Minimum Value: 10
    Maximum Value: 5000
    The maximum width of the property. This field is optional and is present only for the file properties with the GUI image element.
  • Mime Types
    Title: Mime Types

    An array of MIME types. This is an optional field and is present only for properties of type 'file'.

    This field is required in a PUT operation and is optional in a PATCH operation. It is ignored for a property with the gui 'image'.

  • Title: Name
    The name of the property in user's language.

    This field is present for all types of properties. It is returned only by using a GET operation and is ignored in PUT and PATCH operations.

  • Title: Storage Application

    Application label of configured "Oracle Storage" application.

    It is optional for the properties of the "attachments" type and ignored for all other properties.

  • Title: Template
    The template of the property. This field is optional and is present only for the properties of type 'integer' and 'string'.
  • Transformation
    Title: Transformation
    The array of transformation objects. This field is optional and is present only for the properties of type 'string' with the gui 'text'.
  • Translations
    Title: Translations
    The list of associated translations returned for the name the property. The list is returned only if the language parameter is not specified in request.

    This field is present for all the property types. It is required in a PUT operation and optional in a PATCH operation. For the default language, specify the value of the 'name' parameter.

  • Title: Type
    Allowed Values: [ "field", "integer", "string", "enumeration", "file", "attachments" ]
    The type of the property.

    This field is present for all the property types. It is required in a PUT operation and is optional in a PATCH operation. The property type cannot be changed for an existing property.

  • Title: Watermark images with coordinates and datetime

    The parameter is supported for properties with the 'type' = file and ''gui' = 'image'.

    Default: false.

Nested Schema : Mime Types
Type: array
Title: Mime Types

An array of MIME types. This is an optional field and is present only for properties of type 'file'.

This field is required in a PUT operation and is optional in a PATCH operation. It is ignored for a property with the gui 'image'.

Show Source
Nested Schema : Transformation
Type: object
Title: Transformation
The array of transformation objects. This field is optional and is present only for the properties of type 'string' with the gui 'text'.
Show Source
  • regExpLines
    The array of Perl Compatible Regular Expression (PCRE) lines. Each line contains a regular expression rule in the format: = . For example, the following line copies the entire text: /^.*$/m = $0. Lines in the array are applied to the source text successively.
  • The XSLT document used to transform the source text (after processing with regExpLines) to display the property value.
Nested Schema : Translations
Type: array
Title: Translations
The list of associated translations returned for the name the property. The list is returned only if the language parameter is not specified in request.

This field is present for all the property types. It is required in a PUT operation and optional in a PATCH operation. For the default language, specify the value of the 'name' parameter.

Show Source
Nested Schema : regExpLines
Type: array
The array of Perl Compatible Regular Expression (PCRE) lines. Each line contains a regular expression rule in the format: = . For example, the following line copies the entire text: /^.*$/m = $0. Lines in the array are applied to the source text successively.
Show Source
Nested Schema : Translation
Type: object
Show Source
  • This field contains language code of a text translation, it conatains two characters length code in responses (e.g. 'en', 'es') but can be used in requests as extended ISO code (e.g. 'en-US') as well as old two character format.
  • This field is used only in responses and returns ISO language code (e.g. 'en-US'). This field is ignored in the requests (use 'language' instead)

Default Response

This section describes the default error response for this operation.
Body ()
Root Schema : Error
Type: object
Show Source
Back to Top

Examples

The following example shows how to get properties by submitting a GET request on the REST resource.

Example 1

Example of Request Header

The following shows an example of the request header using the limit and offset parameters.

GET /rest/ofscMetadata/v1/properties/?limit=5&offset=2 HTTP/1.1
Host: <instance_name>.fs.ocs.oraclecloud.com 
Authorization: Basic c29hcEBwZXRyb2xpYXNoZXZ5Y2gucmVzdDox 
Accept: */*

Example of Response Header

The following shows an example of the response header.

HTTP/1.1 200 OK
Server: nginx/1.6.3
Date: Wed, 16 Sep 2015 15:32:19 GMT
Content-Type: application/json; charset=utf-8
Connection: close
X-Powered-By: PHP/5.5.28

Example of Response Body

The following example shows the contents of the response body in JSON format.

{ 
    "totalResults":11,
    "limit":5,
    "offset":2,
    "items":[ 
        { 
            "label":"astatus",
            "name":"Activity status",
            "hint":"Status of the activity",
            "type":"field",
            "entity":"activity",
            "gui":"text",
            "translations":[ 
                {
                    "language":"en-us", 
                    "name":"Activity status",
                    "hint":"Status of the activity"
                },
                {
                    "language":"es-es", 
                    "name":"Estado de actividad"
                }
            ],
            "links":[ 
                { 
                    "rel":"canonical",
                    "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/properties/astatus"
                },
                { 
                    "rel":"describedby",
                    "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/metadata-catalog/property"
                }
            ]
        },
        { 
            "label":"EQUIPMENT_BANDWIDTH",
            "name":"Bandwidth",
            "type":"enumeration",
            "entity":"inventory",
            "gui":"combobox",
            "cloneFlag":false,
            "translations":[ 
                {
                    "language":"en-us",
                    "name":"Bandwidth"
                },
                    "language":"es-es",
                    "name":"Ancho de banda"
                }
            ],
            "links":[ 
                { 
                    "rel":"canonical",
                    "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/properties/EQUIPMENT_BANDWIDTH"
                },
                { 
                    "rel":"describedby",
                    "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/metadata-catalog/property"
                },
                { 
                    "rel":"enumerationList",
                    "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/properties/EQUIPMENT_BANDWIDTH/enumserationList"
                }
            ]
        },
        {...},
        {...},
        {...}
    ],
    "links":[ 
        { 
            "rel":"canonical",
            "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/properties/?limit=5&offset=2"
        },
        { 
            "rel":"prev",
            "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/properties/?limit=5&offset=0"
        },
        { 
            "rel":"next",
            "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/properties/?limit=5&offset=7"
        },
        { 
            "rel":"describedby",
            "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/metadata-catalog/properties"
        }
    ]
}

Example 2

Example of Request Header

The following shows an example of the request header using language parameter.

GET /rest/ofscMetadata/v1/properties/Alternative+route?language=en-US HTTP/1.0
Host: <instance_name>.fs.ocs.oraclecloud.com
Authorization: Basic c29hcEBwZXRyb2xpYXNoZXZ5Y2gucmVzdDox
Accept: */*

Example of Response Body

The following example shows the contents of the response body in JSON format.

{
    "label":"Alternative route",
    "name":"Alternative route found and will be used.",
    "hint":"Alternative route",
    "type":"integer",
    "entity":"activity",
    "gui":"checkbox",
    "cloneFlag":false,
    "links":[
        {
            "rel":"canonical",
            "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/properties/Alternative+route"
        },
        {
            "rel":"describedby",
            "href":"https://<instance_name>.fs.ocs.oraclecloud.com/rest/ofscMetadata/v1/metadata-catalog/properties"
        }
    ]
}
Back to Top