The CData Sync App provides a straightforward way to continuously pipeline your Money Forward Expense data to any database, data lake, or data warehouse, making it easily available for Analytics, Reporting, AI, and Machine Learning.
The Money Forward Expense connector can be used from the CData Sync application to pull data from Money Forward Expense and move it to any of the supported destinations.
The Sync App models entities in version 1.x of the Money Forward Expense REST API as relational tables.
For required properties, see the Settings tab.
For connection properties that are not typically required, see the Advanced tab.
The following subsections describe how to authenticate to Money Forward Expense from the three most common authentication flows. For information about how to create a custom OAuth application, see Creating a Custom OAuth Application. For a complete list of connection string properties available in Money Forward Expense, see Connection.
Note: In addition to the connection properties listed below, most Money Forward Expense tables also require the user to set OfficeId.
Automatic refresh of the OAuth access token:
To have the Sync App automatically refresh the OAuth access token:
Manual refresh of the OAuth access token:
The only value needed to manually refresh the OAuth access token is the OAuth refresh token.
Store the OAuth refresh token so that you can use it to manually refresh the OAuth access token after it has expired.
If you are making a desktop application, set the Redirect URI to https://oauth.cdata.com/oauth/, the default CallbackURL value.
Note: Money Forward Expense requires an HTTPS redirect URI.
If you are making a Web application, set the Redirect URI to a page on your Web app where you would like the user to return after authorizing your application.
Note the client Id, client secret, and callback URL for future use.
This section details a selection of advanced features of the Money Forward Expense Sync App.
The Sync App allows you to define virtual tables, called user defined views, whose contents are decided by a pre-configured query. These views are useful when you cannot directly control queries being issued to the drivers. See User Defined Views for an overview of creating and configuring custom views.
Use SSL Configuration to adjust how Sync App handles TLS/SSL certificate negotiations. You can choose from various certificate formats; see the SSLServerCert property under "Connection String Options" for more information.
Configure the Sync App for compliance with Firewall and Proxy, including Windows proxies and HTTP proxies. You can also set up tunnel connections.
The Sync App offloads as much of the SELECT statement processing as possible to Money Forward Expense and then processes the rest of the query in memory (client-side).
See Query Processing for more information.
See Logging for an overview of configuration settings that can be used to refine CData logging. For basic logging, you only need to set two connection properties, but there are numerous features that support more refined logging, where you can select subsets of information to be logged using the LogModules connection property.
By default, the Sync App attempts to negotiate SSL/TLS by checking the server's certificate against the system's trusted certificate store.
To specify another certificate, see the SSLServerCert property for the available formats to do so.
To connect through the Windows system proxy, you do not need to set any additional connection properties. To connect to other proxies, set ProxyAutoDetect to false.
In addition, to authenticate to an HTTP proxy, set ProxyAuthScheme, ProxyUser, and ProxyPassword, in addition to ProxyServer and ProxyPort.
Set the following properties:
The CData Sync App models entities in the Money Forward Expense API as tables, views, and stored procedures. These are defined in schema files, which are text-based, extensible configuration files.
The following sections provide information on executing SQL to the available API Tables and Views. The Sync App offloads as much of the SELECT statement processing as possible to Money Forward Expense and then processes the rest of the query in memory; API limitations and requirements are documented in this section.
Stored Procedures are function-like interfaces to the data source. They can be used to search, update, and modify information in the data source.
The Sync App models the data in Money Forward Expense as a list of tables in a relational database that can be queried using standard SQL statements.
Name | Description |
Departments | Create, update, delete, and query all the report units for an office. |
MyTransactions | Create, update, delete, and query your own transactions. |
OfficeMembers | Query and delete the report units for an office. |
OfficeMemberSettings | Create, update, and query the settings for an office. |
OfficeMemberWorkflows | Create, update, delete, and query the workflows for the members of the specified office. |
Positions | Create, update, delete, and query all the positions for an office. |
Projects | Create, update, delete, and query projects for an office. |
Create, update, delete, and query all the report units for an office.
To get a list of all the departments of an office, the OfficeId column or the OfficeId connection string parameter is required. If not specified, the OfficeId of the first office from the Offices table will be used.
The Sync App uses the Money Forward Expense APIs to process search criteria that refer to OfficeId and processes other filters client-side within the Sync App. For example, following query is processed server side:
SELECT * FROM Departments
To insert a department the following columns are required: OfficeId and Name.
INSERT INTO Departments (OfficeId, Name, Code, Memo) VALUES ('OfficeId123', 'OfficeName123', 'DepCode123', 'Memo123')
To update a department the following columns are required: OfficeId and Id.
UPDATE Departments SET Name = 'NewDepName', Code = 'NewDepCode', Memo = 'NewDepMemo' WHERE OfficeId = '1234' AND Id = '12345'
To delete a department, the following columns are required: OfficeId and Id.
DELETE FROM Departments WHERE OfficeId = '12345' AND Id = '123456'
Name | Type | ReadOnly | Description |
Id [KEY] | String | True |
The department Id. |
OfficeId [KEY] | String | False |
The office Id. |
Name | String | False |
The department name. |
Code | String | False |
The department code. |
Memo | String | False |
The RootId of the department. |
ParentId | String | False |
The ParentId of the department. |
RootId | String | True |
The RootId of the project. |
Create, update, delete, and query your own transactions.
Name | Type | ReadOnly | Description |
Id [KEY] | String | False |
The position Id. |
OfficeId [KEY] | String | False |
The transaction Id. |
Remark | String | False |
The transaction contents. |
Value | Double | False |
The transaction value. |
ItemId | String | False |
The Expense item Id. |
RecognizedAt | Date | False |
The date of payment. |
Number | Integer | True |
The transaction number. |
Memo | String | False |
The transaction notes. |
JpyRate | Double | False |
The exchange rate. |
Currency | String | False |
The transaction currency. |
UseCustomJypRate | Boolean | False |
Indicates if the exchange rate is manually set. |
AutomaticStatus | String | True |
The transaction status. |
ErrorMessage | String | True |
The error message. |
WarningMessage | String | True |
The warning message. |
WaitingMessage | String | True |
The waiting message. |
OfficeMemberId | String | True |
The office member Id. |
CreditItemId | String | False |
The credit account item Id. |
CreditSubItemId | String | False |
The credit account subitem Id. |
ExciseId | String | False |
The tax division Id. |
DepartmentId | String | False |
The department Id. |
ProjectId | String | False |
The project Id. |
CreatedAt | Datetime | True |
The date when the transaction was craeted. |
UpdatedAt | Datetime | True |
The date when the transaction was last updated. |
Query and delete the report units for an office.
To get a list of all the members of an office, the OfficeId column or the OfficeId connection string parameter is required. If not specified, the OfficeId of the first office from the Offices table will be used.
The Sync App uses the Money Forward Expense APIs to process search criteria that refer to OfficeId and processes other filters client-side within the Sync App.
For example, following query is processed server side:
SELECT * FROM OfficeMembers
The column PermissionRoleID may take the value of 0 if the member has been created from the UI, and it hasn't been given any permissions.
To insert an OfficeMember, the following columns are required: OfficeId, Email and PermissionRoleID.
PermissionRoleID can take only these values: 201: general user, 202: recognizer, 203: manager.
-if PermissionRoleID = 201 IsExUser will be set to true
-if PermissionRoleID = 202 IsExUser, IsExAuthorizer will be set to true
-if PermissionRoleID = 203 IsExUser, IsExAuthorizer, IsExAdministrator will be set to true
Departments is a aggregate field, so the value for inserting and updating would be a json string containing an array of objects with its only attribute Department Id
INSERT INTO OfficeMembers (OfficeId, Email, PermissionRoleID) VALUES ('12345', '[email protected]', '201') INSERT INTO OfficeMembers (OfficeId, Email, PermissionRoleID, PositionID, Departments) VALUES ('23457', '[email protected]', '202', '2457', '[{"id": "7457"},{"id": "24577"}]')
To update an OfficeMember you will need the OfficeMember ID and OfficeID specified:
UPDATE OfficeMembers SET Name = 'hello world', Number = '1245', PermissionRoleID = 203 WHERE ID = '345' AND OfficeID = '123' UPDATE OfficeMembers SET Name = 'hey world', Number = '346', PermissionRoleID = 201, PositionID = '2457754', Departments = '[{\"id\": \"457\"},{\"id\": \"346\"}]' WHERE ID = '345' AND OfficeID = '346'
To delete an OfficeMember, the following columns are required: OfficeId, Id.
DELETE FROM OfficeMembers WHERE OfficeId = '12345' AND Id = '123456'
Name | Type | ReadOnly | Description |
Id [KEY] | String | False |
The report unit Id. |
OfficeId [KEY] | String | True |
The report unit Id. |
IdentificationCode | String | True |
The office id. |
Name | String | False |
The report unit title. |
Number | Integer | False |
The report unit title. |
CreatedAt | Datetime | True |
The date when the report unit was created. |
UpdatedAt | Datetime | True |
The date when the report unit was last updated. |
IsExUser | Boolean | True |
The report unit number. |
IsExAuthorizer | Boolean | True |
The report unit number. |
IsExAdministrator | Boolean | True |
The report unit number. |
PositionId | String | True |
The report unit title. |
PositionName | String | True |
The report unit title. |
PositionPriority | Integer | True |
The report unit title. |
PermissionRoleID | String | False |
Permission role ID (Required on insert - 201: general user, 202: recognizer, 203: manager) |
Departments | String | False |
Aggregate field representing departments of an office member. |
Create, update, and query the settings for an office.
To get the settings of an office member, the OfficeId and OfficeMemberId columns are required in the WHERE clause. If not specified, the settings of all the office members will be returned.
The Sync App uses the Money Forward Expense APIs to process search criteria that refer to OfficeId and OfficeMemberId. The Sync App processes other filters client-side within the Sync App. For example, the following query is processed server side:
SELECT * FROM OfficeMemberSettings WHERE OfficeId = '1234' AND OfficeMemberId = '12345'
INSERTs are not supported for this table.
To update the settings of an office member, the following columns required: OfficeId and OfficeMemberId.
UPDATE OfficeMemberSettings SET UseAgent = false, ApprovingPriority = 1234, ProjectId = '1234', CreditItemId = '1234', CreditSubItemId = '1234', TransportationItemId = '1234', DrivingItemId = '1234' WHERE OfficeMemberId = '1234' AND OfficeId = '123456'
Deletes are not supported for this table.
Name | Type | ReadOnly | Description |
Id [KEY] | String | False |
The setting Id. |
OfficeId [KEY] | String | False |
The office Id. |
OfficeMemberId [KEY] | String | False |
The office member Id. |
UseAgent | Boolean | False |
Indicates the use agent status. |
ApprovingPriority | Integer | False |
The approving priority. |
ProjectId | String | False |
The project Id. |
ProjectName | String | True |
The project name. |
ProjectCode | String | True |
The project code. |
CreditItemId | String | False |
The credit item Id. |
CreditItemExciseId | String | True |
The credit item excise Id. |
CreditItemName | String | True |
The credit item name. |
CreditItemCode | String | True |
The credit item code. |
CreditSubItemId | String | False |
The credit subitem Id. |
CreditSubItemItemId | String | True |
The credit subitem item Id. |
CreditSubItemExciseId | String | True |
The credit subitem excise Id. |
CreditSubItemName | String | True |
The credit subitem name. |
CreditSubItemCode | String | True |
The credit subitem code. |
TransportationItemId | String | False |
The transportation item Id. |
TransportationItemName | String | True |
The transportation item name. |
DrivingItemId | String | False |
The driving item Id. |
DrivingItemName | String | True |
The driving item name. |
Create, update, delete, and query the workflows for the members of the specified office.
To get a list of the workflows of an office member, the OfficeId and OfficeMemberId columns are required. If not specified, the workflows of all the office members will be returned by the Money Forward Expense server.
The Sync App uses the Money Forward Expense APIs to process search criteria that refer to OfficeId and OfficeMemberId. Other filters the Sync App processes client-side within the Sync App. For example, the following query is processed server side:
SELECT * FROM OfficeMemberWorkflows WHERE OfficeId = '1234' AND OfficeMemberId = '12345'
To insert a workflow for an office member, the following columns are required: OfficeId, OfficeMemberId, WorkFlowId, and ReportTypeId
INSERT INTO OfficeMemberWorkflows (OfficeId, OfficeMemberId, WorkFlowId, ReportTypeId) VALUES ('123', '12345', '123456', '1234567')
To update a workflow for an office member, the following columns are required: Id, OfficeId, OfficeMemberId, WorkFlowId, AND ReportTypeId.
UPDATE OfficeMemberWorkflows SET WorkFlowId = '123', ReportTypeId = '1234' WHERE OfficeId = '12345' AND OfficeMemberId = '123456' AND Id = '1234567'
Deletes are not supported for this table.
Name | Type | ReadOnly | Description |
Id [KEY] | String | False |
The workflow Id. |
OfficeId [KEY] | String | False |
The office Id. |
OfficeMemberId [KEY] | String | False |
The workflow name. |
WorkflowId | String | False |
The workflow priority. |
ReportTypeId | String | False |
The workflow priority. |
ReportTypeName | String | True |
The workflow priority. |
ReportTypeUseTransactionReserves | Boolean | True |
The workflow priority. |
ReportTypeUseTransactionActionAfterApproval | String | True |
The workflow priority. |
ReportTypeIsActive | Boolean | True |
The workflow priority. |
Create, update, delete, and query all the positions for an office.
To get a list of all the positions of an office, the OfficeId column or the OfficeId connection string parameter is required. If not specified, the OfficeId of the first office from the Offices table will be used.
The Sync App uses the Money Forward Expense APIs to process search criteria that refer to OfficeId and processes other filters client-side within the Sync App. For example, the following query is processed by the Money Forward Expense APIs:
SELECT * FROM Positions
To insert a position the following columns are required: OfficeId and Name.
INSERT INTO Positions (OfficeId, Name, IsAuthorizer, Priority) VALUES ('OfficeId1234', 'PositionName123', false, 150)
To update a position the following columns are required: OfficeId and Id.
UPDATE Positions SET Name = 'UpdatedPositionName', IsAuthorizer = true, Priority = 170 WHERE OfficeId = '12345' AND Id = '123456'
To delete a position, the following columns are required: OfficeId and Id.
DELETE FROM Positions WHERE OfficeId = '12345' AND Id = '123456'
Name | Type | ReadOnly | Description |
Id [KEY] | String | False |
The position Id. |
OfficeId [KEY] | String | False |
The office Id. |
Name | String | False |
The position name. |
IsAuthorizer | Boolean | False |
Indicates if the position is an authorizer. |
Priority | Integer | False |
The position's priority on the list. |
Create, update, delete, and query projects for an office.
To get a list of all the projects of an office, the OfficeId column or the OfficeId connection string parameter is required. If not specified, the OfficeId of the first office from the Offices table will be used.
The Sync App uses the Money Forward Expense APIs to process search criteria that refer to OfficeId and processes other filters client-side within the Sync App. For example, the following query is processed server side:
SELECT * FROM Projects
To insert a project the following columns are required: OfficeId, Name, Code.
INSERT INTO Projects (OfficeId, Name, Code) VALUES ('OfficeId123', 'ProjectName123', 'ProjectCode123')
To update a project the following columns are required: OfficeId, Id.
UPDATE Projects SET Name = 'NewProjectName', Code = 'NewProjectCode' WHERE OfficeId = '12345' AND Id = '123456'
To delete a project, the following columns are required: OfficeId, Id.
DELETE FROM Projects WHERE OfficeId = '12345' AND Id = '123456'
Name | Type | ReadOnly | Description |
Id [KEY] | String | False |
The project Id. |
OfficeId [KEY] | String | False |
The office Id. |
Name | String | False |
The project name. |
Code | String | False |
The project code. |
ParentId | String | True |
The ParentId of the project. |
RootId | String | True |
The RootId of the project. |
Views are similar to tables in the way that data is represented; however, views are read-only.
Queries can be executed against a view as if it were a normal table.
Name | Description |
ApprovingReports | Query the approving reports for an office. |
Excises | Lists the Excises for an office. |
InvoiceReports | null |
Items | Lists the items for an office. |
MyApprovingReports | Query your own approving reports. |
MyInvoiceReports | null |
MyReports | Query your own Reports. |
Offices | Lists all the offices you belong to. |
Reports | Lists the reports for an office. |
ReportUnits | Lists the report units for an office. |
Transactions | Query the transactions for an office. |
Query the approving reports for an office.
Name | Type | Description |
Id [KEY] | String | The report Id. |
OfficeId | String | The office Id. |
ReportTypeId | String | The report type Id. |
OfficeMemberId | String | The office member Id. |
Number | Integer | The report number. |
Title | String | The report title. |
Status | String | The report status. |
SubmittedAt | Datetime | The date when the report was subbmited. |
ApprovedAt | Datetime | The date when the report was approved. |
CreatedAt | Datetime | The date when the report was created. |
UpdatedAt | Datetime | The date when the report was last updated. |
Lists the Excises for an office.
Name | Type | Description |
Id [KEY] | String | The Excise Id. |
OfficeId [KEY] | String | The office Id. |
Rate | String | The Excise Rate. |
Code | String | The Excise Code. |
LongName | String | The Excise LongName. |
null
Name | Type | Description |
Id [KEY] | String | id |
CreatedAt | Datetime | |
OfficeId [KEY] | String | The office id |
ApprovedAt | Datetime | |
Number | String | |
SubmittedAt | Datetime | |
Status | String | |
UpdatedAt | Datetime | |
Title | String | |
OfficeMemberId | String | |
NumberWithoutPrefix | String | number_without_prefix |
ReportApprovals | String | Report Approvals |
Lists the items for an office.
Name | Type | Description |
Id [KEY] | String | The project Id. |
OfficeId [KEY] | String | The office Id. |
Name | String | The item name. |
SubItemId | String | The sub item id. |
Query your own approving reports.
Name | Type | Description |
Id [KEY] | String | The report Id. |
OfficeId | String | The office Id. |
ReportTypeId | String | The report type Id. |
OfficeMemberId | String | The office member Id. |
Number | Integer | The report number. |
Title | String | The report title. |
Status | String | The report status. |
SubmittedAt | Datetime | The date when the report was subbmited. |
ApprovedAt | Datetime | The date when the report was approved. |
CreatedAt | Datetime | The date when the report was created. |
UpdatedAt | Datetime | The date when the report was last updated. |
null
Name | Type | Description |
Id [KEY] | String | id |
CreatedAt | Datetime | |
OfficeId [KEY] | String | The office id |
ApprovedAt | Datetime | |
Number | String | |
SubmittedAt | Datetime | |
Status | String | |
UpdatedAt | Datetime | |
Title | String | |
OfficeMemberId | String | OfficeMemberId |
NumberWithoutPrefix | String | number_without_prefix |
ReportApprovals | String | Report Approvals |
Query your own Reports.
Name | Type | Description |
Id [KEY] | String | The report Id. |
OfficeId | String | The office Id. |
ReportTypeId | String | The report type Id. |
OfficeMemberId | String | The office member Id. |
Number | Integer | The report number. |
Title | String | The report title. |
Status | String | The report status. |
SubmittedAt | Datetime | The date when the report was subbmited. |
ApprovedAt | Datetime | The date when the report was approved. |
CreatedAt | Datetime | The date when the report was created. |
UpdatedAt | Datetime | The date when the report was last updated. |
Lists all the offices you belong to.
The Sync App processes all filters on this table client-side within the Sync App. For example, the following query is the only query processed by the Money Forward Expense APIs and returns a list of all the offices you belong to.
SELECT * FROM Offices
Name | Type | Description |
Id [KEY] | String | The office Id. |
IdentificationCode | String | The identification code for the office. |
Name | String | The office name. |
OfficeTypeId | String | The office type Id. |
Lists the reports for an office.
To get a list of all the reports of an office, the OfficeId column or the OfficeId connection string parameter is required. If not specified, the OfficeId of the first office from the Offices table will be used. The Sync App uses the Money Forward Expense APIs to process search criteria that refer to OfficeId and processes other filters client-side within the Sync App. For example, the following query is processed server side:
SELECT * FROM Reports
Name | Type | Description |
Id [KEY] | String | The report Id. |
OfficeId | String | The office Id. |
ReportTypeId | String | The report type Id. |
OfficeMemberId | String | The office member Id. |
Number | Integer | The report number. |
Title | String | The report title. |
Status | String | The report status. |
SubmittedAt | Datetime | The date when the report was subbmited. |
ApprovedAt | Datetime | The date when the report was approved. |
CreatedAt | Datetime | The date when the report was created. |
UpdatedAt | Datetime | The date when the report was last updated. |
Lists the report units for an office.
To get a list of all the report units of an office, the OfficeId column or the OfficeId connection string parameter is required. If not specified, the OfficeId of the first office from the Offices table will be used.
The Sync App uses the Money Forward Expense APIs to process search criteria that refer to OfficeId and processes other filters client-side within the Sync App. For example, the following query is processed server side:
SELECT * FROM ReportUnits
Name | Type | Description |
Id [KEY] | String | The report unit Id. |
OfficeId | String | The office id. |
Title | String | The report unit title. |
CreatedAt | Datetime | The date when the report unit was created. |
UpdatedAt | Datetime | The date when the report unit was last updated. |
Number | String | The report unit number. |
Query the transactions for an office.
To get a list of all the transactions of an office, the OfficeId column or the OfficeId connection string parameter and a range of RecognizedAt column is required. If OfficeId is not specified, the OfficeId of the first office from the Offices table will be used.
The Sync App uses the Money Forward Expense APIs to process search criteria that refer to OfficeId and processes other filters client-side within the Sync App. For example, the following query is processed server side:
SELECT * FROM Transactions WHERE RecognizedAt <= '2020-04-30' AND RecognizedAt >= '2020-04-01'
To insert a transaction the following columns are required: OfficeId, Remark, ItemId, Value, RecognizedAt.
INSERT INTO Transactions (OfficeId, Remark, ItemId, Value, RecognizedAt, Memo, JpyRate, Currency, UseCustomJpyRate, CreditItemId, CreditSubItemId, ExciseId, DepartmentId, ProjectId) VALUES ('OfficeId123', 'RemarkValue', 'ItemId1234', 100.11, '01-01-2017', 'MemoValue', 100.123, 'JPY', false, 'CreditItemId213', 'CreditSubItemId213', 'ExciseId123', 'DepartmentId123', 'ProjectId123')
To update a transaction the following columns are required: OfficeId, Id. You can update the transactions that belong the authenticated user, but not those that belong to the other office members.
UPDATE Transactions SET Remark = 'NewRemark', ItemId = 'NewItemId', Value = 123.123, Memo = 'NewMemo', UseCustomJypRate = false, RecognizedAt = '01-02-2018', Currency = 'USD', ExciseId = 'NewExciseId', CreditItemId = 'NewCreditItemId', CreditSubItemId = 'NewCreditSubItemId', DepartmentId = 'NewDepartmentId', ProjectId = 'NewProjectId' WHERE OfficeId = '12345' AND Id = '123456'
To delete a transaction, the following columns are required: OfficeId, Id. You can delete the transactions that belong the authenticated user, but not those that belong to the other office members.
DELETE FROM Transactions WHERE OfficeId = '12345' AND Id = '123456'
Name | Type | Description |
Id [KEY] | String | The position Id. |
OfficeId [KEY] | String | The transaction Id. |
Remark | String | The transaction contents. |
Value | Double | The transaction value. |
ItemId | String | The Expense item Id. |
RecognizedAt | Date | The date of payment. |
Number | Integer | The transaction number. |
Memo | String | The transaction notes. |
JpyRate | Double | The exchange rate. |
Currency | String | The transaction currency. |
UseCustomJypRate | Boolean | Indicates if the exchange rate is manually set. |
AutomaticStatus | String | The transaction status. |
ErrorMessage | String | The error message. |
WarningMessage | String | The warning message. |
WaitingMessage | String | The waiting message. |
OfficeMemberId | String | The office member Id. |
CreditItemId | String | The credit account item Id. |
CreditSubItemId | String | The credit account subitem Id. |
ExciseId | String | The tax division Id. |
DepartmentId | String | The department Id. |
ProjectId | String | The project Id. |
CreatedAt | Datetime | The date when the transaction was craeted. |
UpdatedAt | Datetime | The date when the transaction was last updated. |
The connection string properties are the various options that can be used to establish a connection. This section provides a complete list of the options you can configure in the connection string for this provider. Click the links for further details.
For more information on establishing a connection, see Establishing a Connection.
Property | Description |
OfficeId | Id of the office. Required for most queries. |
Property | Description |
OAuthClientId | The client Id assigned when you register your application with an OAuth authorization server. |
OAuthClientSecret | The client secret assigned when you register your application with an OAuth authorization server. |
Property | Description |
SSLServerCert | The certificate to be accepted from the server when connecting using TLS/SSL. |
Property | Description |
FirewallType | The protocol used by a proxy-based firewall. |
FirewallServer | The name or IP address of a proxy-based firewall. |
FirewallPort | The TCP port for a proxy-based firewall. |
FirewallUser | The user name to use to authenticate with a proxy-based firewall. |
FirewallPassword | A password used to authenticate to a proxy-based firewall. |
Property | Description |
ProxyAutoDetect | This indicates whether to use the system proxy settings or not. |
ProxyServer | The hostname or IP address of a proxy to route HTTP traffic through. |
ProxyPort | The TCP port the ProxyServer proxy is running on. |
ProxyAuthScheme | The authentication type to use to authenticate to the ProxyServer proxy. |
ProxyUser | A user name to be used to authenticate to the ProxyServer proxy. |
ProxyPassword | A password to be used to authenticate to the ProxyServer proxy. |
ProxySSLType | The SSL type to use when connecting to the ProxyServer proxy. |
ProxyExceptions | A semicolon separated list of destination hostnames or IPs that are exempt from connecting through the ProxyServer . |
Property | Description |
LogModules | Core modules to be included in the log file. |
Property | Description |
Location | A path to the directory that contains the schema files defining tables, views, and stored procedures. |
BrowsableSchemas | This property restricts the schemas reported to a subset of the available schemas. For example, BrowsableSchemas=SchemaA,SchemaB,SchemaC. |
Tables | This property restricts the tables reported to a subset of the available tables. For example, Tables=TableA,TableB,TableC. |
Views | Restricts the views reported to a subset of the available tables. For example, Views=ViewA,ViewB,ViewC. |
Property | Description |
MaxRows | Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses. |
Other | These hidden properties are used only in specific use cases. |
PseudoColumns | This property indicates whether or not to include pseudo columns as columns to the table. |
Timeout | The value in seconds until the timeout error is thrown, canceling the operation. |
UserDefinedViews | A filepath pointing to the JSON configuration file containing your custom views. |
This section provides a complete list of the Authentication properties you can configure in the connection string for this provider.
Property | Description |
OfficeId | Id of the office. Required for most queries. |
Id of the office. Required for most queries.
Id of the office. Required for most queries. This value restricts query results to the specified office. If you do not have direct access to the SQL query, you can set this connection property instead.
If you do have access to the query, you can override the connection property value for a specific query by setting the OfficeId pseudo column.
This section provides a complete list of the OAuth properties you can configure in the connection string for this provider.
Property | Description |
OAuthClientId | The client Id assigned when you register your application with an OAuth authorization server. |
OAuthClientSecret | The client secret assigned when you register your application with an OAuth authorization server. |
The client Id assigned when you register your application with an OAuth authorization server.
As part of registering an OAuth application, you will receive the OAuthClientId value, sometimes also called a consumer key, and a client secret, the OAuthClientSecret.
The client secret assigned when you register your application with an OAuth authorization server.
As part of registering an OAuth application, you will receive the OAuthClientId, also called a consumer key. You will also receive a client secret, also called a consumer secret. Set the client secret in the OAuthClientSecret property.
This section provides a complete list of the SSL properties you can configure in the connection string for this provider.
Property | Description |
SSLServerCert | The certificate to be accepted from the server when connecting using TLS/SSL. |
The certificate to be accepted from the server when connecting using TLS/SSL.
If using a TLS/SSL connection, this property can be used to specify the TLS/SSL certificate to be accepted from the server. Any other certificate that is not trusted by the machine is rejected.
This property can take the following forms:
Description | Example |
A full PEM Certificate (example shortened for brevity) | -----BEGIN CERTIFICATE----- MIIChTCCAe4CAQAwDQYJKoZIhv......Qw== -----END CERTIFICATE----- |
A path to a local file containing the certificate | C:\cert.cer |
The public key (example shortened for brevity) | -----BEGIN RSA PUBLIC KEY----- MIGfMA0GCSq......AQAB -----END RSA PUBLIC KEY----- |
The MD5 Thumbprint (hex values can also be either space or colon separated) | ecadbdda5a1529c58a1e9e09828d70e4 |
The SHA1 Thumbprint (hex values can also be either space or colon separated) | 34a929226ae0819f2ec14b4a3d904f801cbb150d |
If not specified, any certificate trusted by the machine is accepted.
Use '*' to signify to accept all certificates. Note that this is not recommended due to security concerns.
This section provides a complete list of the Firewall properties you can configure in the connection string for this provider.
Property | Description |
FirewallType | The protocol used by a proxy-based firewall. |
FirewallServer | The name or IP address of a proxy-based firewall. |
FirewallPort | The TCP port for a proxy-based firewall. |
FirewallUser | The user name to use to authenticate with a proxy-based firewall. |
FirewallPassword | A password used to authenticate to a proxy-based firewall. |
The protocol used by a proxy-based firewall.
This property specifies the protocol that the Sync App will use to tunnel traffic through the FirewallServer proxy. Note that by default, the Sync App connects to the system proxy; to disable this behavior and connect to one of the following proxy types, set ProxyAutoDetect to false.
Type | Default Port | Description |
TUNNEL | 80 | When this is set, the Sync App opens a connection to Money Forward Expense and traffic flows back and forth through the proxy. |
SOCKS4 | 1080 | When this is set, the Sync App sends data through the SOCKS 4 proxy specified by FirewallServer and FirewallPort and passes the FirewallUser value to the proxy, which determines if the connection request should be granted. |
SOCKS5 | 1080 | When this is set, the Sync App sends data through the SOCKS 5 proxy specified by FirewallServer and FirewallPort. If your proxy requires authentication, set FirewallUser and FirewallPassword to credentials the proxy recognizes. |
To connect to HTTP proxies, use ProxyServer and ProxyPort. To authenticate to HTTP proxies, use ProxyAuthScheme, ProxyUser, and ProxyPassword.
The name or IP address of a proxy-based firewall.
This property specifies the IP address, DNS name, or host name of a proxy allowing traversal of a firewall. The protocol is specified by FirewallType: Use FirewallServer with this property to connect through SOCKS or do tunneling. Use ProxyServer to connect to an HTTP proxy.
Note that the Sync App uses the system proxy by default. To use a different proxy, set ProxyAutoDetect to false.
The TCP port for a proxy-based firewall.
This specifies the TCP port for a proxy allowing traversal of a firewall. Use FirewallServer to specify the name or IP address. Specify the protocol with FirewallType.
The user name to use to authenticate with a proxy-based firewall.
The FirewallUser and FirewallPassword properties are used to authenticate against the proxy specified in FirewallServer and FirewallPort, following the authentication method specified in FirewallType.
A password used to authenticate to a proxy-based firewall.
This property is passed to the proxy specified by FirewallServer and FirewallPort, following the authentication method specified by FirewallType.
This section provides a complete list of the Proxy properties you can configure in the connection string for this provider.
Property | Description |
ProxyAutoDetect | This indicates whether to use the system proxy settings or not. |
ProxyServer | The hostname or IP address of a proxy to route HTTP traffic through. |
ProxyPort | The TCP port the ProxyServer proxy is running on. |
ProxyAuthScheme | The authentication type to use to authenticate to the ProxyServer proxy. |
ProxyUser | A user name to be used to authenticate to the ProxyServer proxy. |
ProxyPassword | A password to be used to authenticate to the ProxyServer proxy. |
ProxySSLType | The SSL type to use when connecting to the ProxyServer proxy. |
ProxyExceptions | A semicolon separated list of destination hostnames or IPs that are exempt from connecting through the ProxyServer . |
This indicates whether to use the system proxy settings or not.
This takes precedence over other proxy settings, so you'll need to set ProxyAutoDetect to FALSE in order use custom proxy settings.
To connect to an HTTP proxy, see ProxyServer. For other proxies, such as SOCKS or tunneling, see FirewallType.
The hostname or IP address of a proxy to route HTTP traffic through.
The hostname or IP address of a proxy to route HTTP traffic through. The Sync App can use the HTTP, Windows (NTLM), or Kerberos authentication types to authenticate to an HTTP proxy.
If you need to connect through a SOCKS proxy or tunnel the connection, see FirewallType.
By default, the Sync App uses the system proxy. If you need to use another proxy, set ProxyAutoDetect to false.
The TCP port the ProxyServer proxy is running on.
The port the HTTP proxy is running on that you want to redirect HTTP traffic through. Specify the HTTP proxy in ProxyServer. For other proxy types, see FirewallType.
The authentication type to use to authenticate to the ProxyServer proxy.
This value specifies the authentication type to use to authenticate to the HTTP proxy specified by ProxyServer and ProxyPort.
Note that the Sync App will use the system proxy settings by default, without further configuration needed; if you want to connect to another proxy, you will need to set ProxyAutoDetect to false, in addition to ProxyServer and ProxyPort. To authenticate, set ProxyAuthScheme and set ProxyUser and ProxyPassword, if needed.
The authentication type can be one of the following:
If you need to use another authentication type, such as SOCKS 5 authentication, see FirewallType.
A user name to be used to authenticate to the ProxyServer proxy.
The ProxyUser and ProxyPassword options are used to connect and authenticate against the HTTP proxy specified in ProxyServer.
You can select one of the available authentication types in ProxyAuthScheme. If you are using HTTP authentication, set this to the user name of a user recognized by the HTTP proxy. If you are using Windows or Kerberos authentication, set this property to a user name in one of the following formats:
user@domain domain\user
A password to be used to authenticate to the ProxyServer proxy.
This property is used to authenticate to an HTTP proxy server that supports NTLM (Windows), Kerberos, or HTTP authentication. To specify the HTTP proxy, you can set ProxyServer and ProxyPort. To specify the authentication type, set ProxyAuthScheme.
If you are using HTTP authentication, additionally set ProxyUser and ProxyPassword to HTTP proxy.
If you are using NTLM authentication, set ProxyUser and ProxyPassword to your Windows password. You may also need these to complete Kerberos authentication.
For SOCKS 5 authentication or tunneling, see FirewallType.
By default, the Sync App uses the system proxy. If you want to connect to another proxy, set ProxyAutoDetect to false.
The SSL type to use when connecting to the ProxyServer proxy.
This property determines when to use SSL for the connection to an HTTP proxy specified by ProxyServer. This value can be AUTO, ALWAYS, NEVER, or TUNNEL. The applicable values are the following:
AUTO | Default setting. If the URL is an HTTPS URL, the Sync App will use the TUNNEL option. If the URL is an HTTP URL, the component will use the NEVER option. |
ALWAYS | The connection is always SSL enabled. |
NEVER | The connection is not SSL enabled. |
TUNNEL | The connection is through a tunneling proxy. The proxy server opens a connection to the remote host and traffic flows back and forth through the proxy. |
A semicolon separated list of destination hostnames or IPs that are exempt from connecting through the ProxyServer .
The ProxyServer is used for all addresses, except for addresses defined in this property. Use semicolons to separate entries.
Note that the Sync App uses the system proxy settings by default, without further configuration needed; if you want to explicitly configure proxy exceptions for this connection, you need to set ProxyAutoDetect = false, and configure ProxyServer and ProxyPort. To authenticate, set ProxyAuthScheme and set ProxyUser and ProxyPassword, if needed.
This section provides a complete list of the Logging properties you can configure in the connection string for this provider.
Property | Description |
LogModules | Core modules to be included in the log file. |
Core modules to be included in the log file.
Only the modules specified (separated by ';') will be included in the log file. By default all modules are included.
See the Logging page for an overview.
This section provides a complete list of the Schema properties you can configure in the connection string for this provider.
Property | Description |
Location | A path to the directory that contains the schema files defining tables, views, and stored procedures. |
BrowsableSchemas | This property restricts the schemas reported to a subset of the available schemas. For example, BrowsableSchemas=SchemaA,SchemaB,SchemaC. |
Tables | This property restricts the tables reported to a subset of the available tables. For example, Tables=TableA,TableB,TableC. |
Views | Restricts the views reported to a subset of the available tables. For example, Views=ViewA,ViewB,ViewC. |
A path to the directory that contains the schema files defining tables, views, and stored procedures.
The path to a directory which contains the schema files for the Sync App (.rsd files for tables and views, .rsb files for stored procedures). The folder location can be a relative path from the location of the executable. The Location property is only needed if you want to customize definitions (for example, change a column name, ignore a column, and so on) or extend the data model with new tables, views, or stored procedures.
If left unspecified, the default location is "%APPDATA%\\CData\\MFExpense Data Provider\\Schema" with %APPDATA% being set to the user's configuration directory:
Platform | %APPDATA% |
Windows | The value of the APPDATA environment variable |
Linux | ~/.config |
This property restricts the schemas reported to a subset of the available schemas. For example, BrowsableSchemas=SchemaA,SchemaB,SchemaC.
Listing the schemas from databases can be expensive. Providing a list of schemas in the connection string improves the performance.
This property restricts the tables reported to a subset of the available tables. For example, Tables=TableA,TableB,TableC.
Listing the tables from some databases can be expensive. Providing a list of tables in the connection string improves the performance of the Sync App.
This property can also be used as an alternative to automatically listing views if you already know which ones you want to work with and there would otherwise be too many to work with.
Specify the tables you want in a comma-separated list. Each table should be a valid SQL identifier with any special characters escaped using square brackets, double-quotes or backticks. For example, Tables=TableA,[TableB/WithSlash],WithCatalog.WithSchema.`TableC With Space`.
Note that when connecting to a data source with multiple schemas or catalogs, you will need to provide the fully qualified name of the table in this property, as in the last example here, to avoid ambiguity between tables that exist in multiple catalogs or schemas.
Restricts the views reported to a subset of the available tables. For example, Views=ViewA,ViewB,ViewC.
Listing the views from some databases can be expensive. Providing a list of views in the connection string improves the performance of the Sync App.
This property can also be used as an alternative to automatically listing views if you already know which ones you want to work with and there would otherwise be too many to work with.
Specify the views you want in a comma-separated list. Each view should be a valid SQL identifier with any special characters escaped using square brackets, double-quotes or backticks. For example, Views=ViewA,[ViewB/WithSlash],WithCatalog.WithSchema.`ViewC With Space`.
Note that when connecting to a data source with multiple schemas or catalogs, you will need to provide the fully qualified name of the table in this property, as in the last example here, to avoid ambiguity between tables that exist in multiple catalogs or schemas.
This section provides a complete list of the Miscellaneous properties you can configure in the connection string for this provider.
Property | Description |
MaxRows | Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses. |
Other | These hidden properties are used only in specific use cases. |
PseudoColumns | This property indicates whether or not to include pseudo columns as columns to the table. |
Timeout | The value in seconds until the timeout error is thrown, canceling the operation. |
UserDefinedViews | A filepath pointing to the JSON configuration file containing your custom views. |
Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses.
Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses.
These hidden properties are used only in specific use cases.
The properties listed below are available for specific use cases. Normal driver use cases and functionality should not require these properties.
Specify multiple properties in a semicolon-separated list.
DefaultColumnSize | Sets the default length of string fields when the data source does not provide column length in the metadata. The default value is 2000. |
ConvertDateTimeToGMT | Determines whether to convert date-time values to GMT, instead of the local time of the machine. |
RecordToFile=filename | Records the underlying socket data transfer to the specified file. |
This property indicates whether or not to include pseudo columns as columns to the table.
This setting is particularly helpful in Entity Framework, which does not allow you to set a value for a pseudo column unless it is a table column. The value of this connection setting is of the format "Table1=Column1, Table1=Column2, Table2=Column3". You can use the "*" character to include all tables and all columns; for example, "*=*".
The value in seconds until the timeout error is thrown, canceling the operation.
If Timeout = 0, operations do not time out. The operations run until they complete successfully or until they encounter an error condition.
If Timeout expires and the operation is not yet complete, the Sync App throws an exception.
A filepath pointing to the JSON configuration file containing your custom views.
User Defined Views are defined in a JSON-formatted configuration file called UserDefinedViews.json. The Sync App automatically detects the views specified in this file.
You can also have multiple view definitions and control them using the UserDefinedViews connection property. When you use this property, only the specified views are seen by the Sync App.
This User Defined View configuration file is formatted as follows:
For example:
{ "MyView": { "query": "SELECT * FROM Offices WHERE MyColumn = 'value'" }, "MyView2": { "query": "SELECT * FROM MyTable WHERE Id IN (1,2,3)" } }Use the UserDefinedViews connection property to specify the location of your JSON configuration file. For example:
"UserDefinedViews", C:\Users\yourusername\Desktop\tmp\UserDefinedViews.jsonNote that the specified path is not embedded in quotation marks.