AppEnablementAPI_TypesAndValues.ttcn 6.07 KB
Newer Older
YannGarcia's avatar
YannGarcia committed
/**
 * @desc The ETSI MEC ISG MEC011 Application Enablement API described using OpenAPI
 * @see http://www.etsi.org/deliver/etsi_gs/MEC/001_099/011/01.01.01_60/gs_mec011v010101p.pdf
 */
module AppEnablementAPI_TypesAndValues {

  // JSON
  import from JSON all;
 
  // LibCommon
  import from LibCommon_BasicTypesAndValues all;

  /**
   * @desc Problem Details for HTTP APIs
   * @member type_ A URI reference according to IETF RFC 3986 that identifies the problem type
   * @member title A short, human-readable summary of the problem type
   * @member status The HTTP status code for this occurrence of the problem
   * @member detail A human-readable explanation specific to this occurrence of the problem
   * @member instance A URI reference that identifies the specific occurrence of the problem
   * @see IETF RFC 7807 Clause 3.  The Problem Details JSON Object
   */
  type record ProblemDetails {
    JSON.String type_,
    JSON.String title,
    UInt32 status,
    JSON.String detail,
    JSON.String instance
  } with {
    variant (type_) "name as 'type'";
  }

  /**
   * @desc Information on available applications.
   */
  type record ApplicationList {
    AppInfo appInfo,
    VendorSpecificExt vendorSpecificExt
  }

  /**
   * @desc Information on application context created by the MEC system.
   */
  type record AppContext {
    ContextId contextId,
    AssociateUeAppId associateUeAppId,
    RequiredAppInfo appInfo,
    CallbackReference callbackReference optional
  }

  /**
   * @desc The parameters used in the method "Receiving notification events".
   */
  type record NotificationEvent {
    ReferenceURL referenceURI
  }

  /**
   * @desc Extension for vendor specific information.
   */
  type record length(0..infinity) of VendorSpecificExt VendorSpecificExtList;

  /**
   * @desc Extension for vendor-specific information.
   */
  type record VendorSpecificExt {
    VendorId vendorId
  }

  /**
   * @desc Uniquely identifies the application context in the MEC system. Assigned by the MEC system and included in the response. The length of the value shall not exceed 32 characters.
   */
  type JSON.String ContextId length(1..32) with {encode "length(1..32)"};

  /**
   * @desc Uniquely identifies the UE application. Included in the request. The length of the value shall not exceed 32 characters.
   */
  type JSON.String AssociateUeAppId length(1..32) with {encode "length(1..32)"};

  /**
   * @desc Vendor identifier. The length of the value shall not exceed 32 characters. The rest of the structure of this vendor specific extension is not defined.
   */
  type JSON.String VendorId;

  /**
   * @desc User applications available for the UE application.
   */
  type record of AppInfoList AppInfo;

  /**
   * @desc User applications available for the UE application.
   */
  type record AppInfoList {
    AppName appName,
    AppProvider appProvider,
    AppDescription appDescription,
    AppSoftVersion appSoftVersion optional,
    AppCharcs appCharcs optional
  }

  /**
   * @desc Included in the request.
   */
  type record RequiredAppInfo {
    AppName appName,
    AppProvider appProvider,
    ReferenceURL referenceURL,
    AppSoftVersion appSoftVersion optional,
    AppDescription appDescription optional,
    AppPackageSource appPackageSource optional
  }

  /**
   * @desc The application characteristics relate to the system resources consumed by the application. UE application can use this information e.g., for estimating the cost of use of the application or for the expected user experience.
   */
  type record AppCharcs {
    Memory memory,
    Storage storage,
    Latency latency,
    Bandwidth bandwidth,
    ServiceCont serviceCont
  }

  /**
   * @desc The maximum size in Mbytes of the memory resource reserved for the MEC application instance in the MEC system.
   */
  type UInt32 Memory;

  /**
   * @desc The maximum size in Mbytes of the storage resource expected to be used by the MEC application instance in the MEC system.
   */
  type UInt32 Storage;

  /**
   * @desc The target round trip time in milliseconds supported by the MEC system for the MEC application instance.
   */
  type UInt32 Latency;

  /**
   * @desc The required connection bandwidth in kbit/s for the use of the mobile edge application instance.
   */
  type UInt32 Bandwidth;

  /**
   * @desc Required service continuity mode for this application.
   */
  type enumerated ServiceCont {
    SERVICE_CONTINUITY_NOT_REQUIRED,
    SERVICE_CONTINUITY_REQUIRED
  }

  /**
   * @desc Name of the MEC application. The length of the value shall not exceed 32 characters.
   */
  type JSON.String AppName length(1..32) with {encode "length(1..32)"};

  /**
   * @desc Provider of the MEC application. The length of the value shall not exceed 32 characters.
   */
  type JSON.String AppProvider length(1..32) with {encode "length(1..32)"};

  /**
   * @desc Software version of the MEC application. The length of the value shall not exceed 32 characters.
   */
  type JSON.String AppSoftVersion length(1..32) with {encode "length(1..32)"};

  /**
   * @desc Human readable description of the MEC application. NOTE the language support may be limited. The length of the value shall not exceed 128 characters.
   */
  type JSON.String AppDescription length(1..128) with {encode "length(1..128)"};

  /**
   * @desc URI assigned by the UE application to receive application lifecycle related notifications. Included in the request. This subscription stays alive for the lifetime of the application context.
   */
  type JSON.String CallbackReference;

  /**
   * @desc Address of the user application. Used as the reference URL for the application. Assigned by the MEC system and included in the response.
   */
  type JSON.AnyURI ReferenceURL;

  /**
   * @desc URI of the application package. Included in the request if the application is not one in the ApplicationList. appPackageSource enables on-boarding of the application package into the MEC system. The application package shall comply with the definitions in clause 6.2.1.2 of ETSI GS MEC 010-2.
   */
  type JSON.AnyURI AppPackageSource;
  
} with {
  encode "JSON"
} // End of module AppEnablementAPI_TypesAndValues