Fautore API: fauAppReg
Applications are the end points between which data is transferred. Both sending and receiving applications must be registered with Fautore.
Table of contents
Overview
Upon application approval by an application manager a permission named for the application is created.
Approved applications are made available to Tribe Members granted permission the associated permission. Tribe members must enroll in the available application to be able to transact data using that application. Enrollment is the process of providing criterion specific to that user for the registered application.
Fautore provides a "preferred" flag indicating the app is preferred by the Tribe member end user for receiving data. The host owner has the ultimate authority over how data is delivered to each requesting end user.
Limitations
NATTNone At This Time
Relevant Tribe Configuration Parameters
NATTNone At This Time
Registration Criteria
Function: fauRegApp
Source:
All data is provided by registering application. Alternatively, Fautore screens could be developed at a future time for the manual registration of an application.
{ "Func": "fauRegApp" { "AppName": r-str(45) Descriptive application name, spaces allowed "Description": r-str(512) Info to aid enablement decision by app manager "UserName": r-str(45) User name of registering member, must verify, "AppPush": r-boo Flag (0,1) indicating if application pushes data to Fautore "FauPull": r-boo Flag (0,1) indicating if Fautore pulls data from application "DefVals": { "Computer": o-str(45) Host name or IP address of application host "Port": o-int Application port number on application host computer "AppUser": o-str(45) Application user name on remote computer "AppPass": o-str(45) Application user password on remote computer "Interval": o-int Interval at which application interaction should occur } "AppVals" [ { "TechName": r-str Technical name for described field "Length": r-int Length of dynamic application field "Value": o-str(128) Value for application specific field "DispName" r-str(64) Field name in dynamically created forms "DataType" r-str(16) Data type stored in the dynamic application variable } ] }
$json = '{ "Func": "fauRegApp", "AppName": "fauEmail", "Description": "Email utility to treat a mail server as a contributing team member", "UserName": "Crazed1", "AppPush": 1, "FauPull": 0, "DefVals": {"Computer": "Thor.cichosz.org", "Port": 26, "AppUser": "Marvin", "AppPass": "R0bot", "Interval": 300 }, "AppVals": [ { "TechName": "catalog" "DispName": "Catalog", "DataType": "Str", "Length": 42, "Value": "Spring" }, { "TechName": "persKey" "DispName": "Personal Key", "DataType": "Str", "Length": 69, "Value": "ajhdfyuqw487qqweiaisfg6480403er" } ] }';
The response returned is a 2 field JSON structure:
- Positive numbers indicate success
- Negative numbers indicate rejection
- NULL = Request failure, programmatic error
Mesg:
- Descriptive text explaining the MsgId
Upon Success:
- MsgId = 1
- Mesg = Fautore id for the application reference
Upon Rejection:
- MsgId = negative reason code (table of codes TBD)
- Mesg = Text of message describing reason for rejection (i.e. Application already registered for user.)
Upon Failure:
- NULL
Data Mapping
Data accepted by the fauAppReg function stores it's data as indicated in the below table.
Note:
- The RegApps table must be populated before the Apps table
- The RegApps:AppId generated for the application is reused in the Apps table
JSON | Table | Field | Comments |
---|---|---|---|
AppName | RegApps | AppName | Straight copy from JSON to table. |
Description | RegApps | Description | Straight copy from JSON to table. |
UserName | RegApps | UserName | Verified against "User" table before insertion. |
AppPush | RegApps | AppPush | Straight copy from JSON to table. |
FauPull | RegApps | FauPull | Straight copy from JSON to table. |
DefVals | - | - | Pointer to default values for the application. These values are supplied to Tribe Members as defaults when they enroll in application use. |
Computer | Apps | Computer | The hostname or IP address of the computer hosting the application. This value must be verified as being within the FOD. |
Port | Apps | Port | The port on the host computer by which the application is accessed. |
AppUser | Apps | AppUser | Login id used to access the application. |
AppPass | Apps | AppPass | Password associated with AppUser. This is a problem point. we need a way to store this information securely, yet still be able to pass it back to the application later n a form it understads. |
Interval | Apps | Interval | Number of seconds between iterations of accessing the application. |
- | Apps | User_UID | This value is not passed from the application. This is always "default" to indicate this is the default value set for the application. There should always be 1 and only 1 of these records associate with any application. |
- | Apps | RegApps_AppId | The unique application id assigned when data was stored to the RegApp table. |
Workflows
Registration is the process of making an application available to Fautore. A registered application is not useable until after it has been configured and activited by a Application ManagerAn application manager is any tribe member with the "Manage Apps" privelege..
- Application queries Fautore well known port in the IANA "User Ports" range with a registration request.
- Fautore returns Dynamic port address of Registration Service
- Application sends registration criteria to Registration Service
- Registration service verifies provided TUID exists
- Registration service verifies provided password matches for the TUID
- Registration service Verifies provided TUID has privileges to register application
- Registration service creates Unique Fautore ID (UFID) for application
- Registration service creates a record for the application in the "Apps" table
- Unique Fautore Identifier (UFID)
- Tribe User Id of registering user
- AppPush value
- FauPull value
- Registration date
- Default for "Computer" if provided (IP/Hostname)
- Default for "Port" if provided
- Default for "appUser" if provided
- Default for "appPass" if provided
- Default for "Interval" if provided
- Registration service creates a new record in the "AppSpecs" table for each set of application specific field values provided.
Once an application is registered with the Tribe it must be configured to function correctly with values specifying how to interact with the remote data source. After configuration is complete the application is then activated (With the click of a checkbox).
- Application ManagerAn application manager is any tribe member with the "Manage Apps" privilege. logs into the Tribe.
- Application Manager brings up the "Application Management" screen.
- Application Management screen presents a list of registered applications and their "Active" status.
- Application name is a link to an "Application Detailed Information" screen.
- Application Manager clicks link for newly added application.
- Fautore builds "Application Detailed Information" screen
- Standard fields stored by the tribe are selected from the "Apps" table for the application.
- Application specific data descriptors are selected from "AppSpecs"
- Any values associated with the application data descriptors are selected from the "AppSpecData" table.
- The page is built using the "Apps" data as default for the standard form fields, the "AppSpecs" data to construct the form fields for the application specific data and the data pulled from "AppSpecsData" as the default values for the application specific fields.
- Application Manager fills in any missing data and saves the form.
- The Application Manager is returned to the "Application Management" screen
- Application Manager clicks the "Active" checkbox to activate the application for tribe use
- Fautore verifies the parameters of the application access systems only within the Fautore Operational Domain (FOD).
- If the "Computer" value for the application is a FQDN the domain name portion must match that of the Tribe FQDN or be "localhost"
- If the "Computer" value for the application is an IP address it must fall within the Ethernet IP broadcast mapping for the local LAN.
- The application is marked as "active" with a successful FOD verification or an appropriate error is present otherwise.
This section is provided for context only. Exact steps for mapping applications to tribe members and activities are yet to be determined.
- Coterie Chief selects from active list of applications to enable them for use in their individual Coterie.
- Any Tribe member with sufficient privilege for creating instructions accesses the "Instruction Definition" screen.
- The "Data Source" section of the screen present fields listing Tribe/Coterie Members, Applications, "RegEx" filter defs for "Summary Content" and "Detail Content," and a "Data Type" pull down that would list values such as "Text," "Images," "Sound" and "Video."
- The "Data Destination" section of the screen present fields listing Tribe/Coterie Members, Applications, "RegEx" filter defs for "Summary Content" and "Detail Content," and a "Data Type" pull down that would list values such as "Text," "Images," "Sound" and "Video."
- Tribe Member selects an application from the source dropdown
- Tribe member selects any additional criteria to narrow down the source trigger.
- Tribe member selects an application from the destinations dropdown.
- Tribe member select data types to send
- Tribe member save rule
- Any data placed into the staging area matching the terms of the "source" portion of the rule will be sent to the destination application.