High-level RESTful Web service attributes

Table 1. High-level RESTful web services attributes
Attribute Description
WSAttachment
Defines file attachments in the REST message.
WSContext
Defines an injection variable to retrieve REST operation context values at the service level.
WSCookie
Allows cookies to be passed to Web service REST function.
WSError= "description"
Specifies a description of the status-code that is returned in the HTTP response.
WSDelete
In order to remove an existing resource, you set the WSDelete attribute.
WSDescription
Specifies a description.
WSGet
In order to retrieve a resource, you set the WSGet attribute.
WSHeader
Defines custom headers in the request and response of Web service functions.
WSInfo
Specify information about the Web service such as title, version, contact details, etc.
WSMedia = " MIME-type [,...]"
Defines the data format of the REST message.
WSName
Specify alternative names for parameters in a REST function.
WSOptional
Qualifies an attribute as optional in a REST function.
WSParam
Specifies a value for a template path to a REST Web service resource.
WSPath = "/{ path-element | value-template } [/...]"
Specifies a path to a REST Web service resource that identifies its function and allows parameters to be passed in the URL.
WSPost
In order to create a new resource, you set the WSPost attribute.
WSPut
Update an existing resource with the WSPut attribute.
WSQuery
Specifies parameters to be passed in the URL query string.
WSRetCode= "{ code | code:description } "
Defines the HTTP status sent in the REST response.
WSScope = "{ scope } [,...]"
Specify security in the REST service via scopes.
WSThrows = "{ code | code:description | code:@variable } [,...]"
Defines a list of errors that may be encountered accessing a REST resource.