LibOFX: libofx.h Source File

LibOFX

- Main Page
- Namespaces
- Data Structures
- Files

- File List
- Globals

libofx-0.9.12/inc/libofx.h
Go to the documentation of this file.
1 /*-*-c-*-*******************************************************************
2 libofx.h - Main header file for the libofx API
3 -------------------
4 copyright : (C) 2002-2011 by Benoit Grégoire
5 email : benoitg@coeus.ca
6 ***************************************************************************/
26 /***************************************************************************
27 * *
28 * This program is free software; you can redistribute it and/or modify *
29 * it under the terms of the GNU General Public License as published by *
30 * the Free Software Foundation; either version 2 of the License, or *
31 * (at your option) any later version. *
32 * *
33 ***************************************************************************/
34
35 #ifndef LIBOFX_H
36 #define LIBOFX_H
37 #include <time.h>
38
39 #define LIBOFX_MAJOR_VERSION 0
40 #define LIBOFX_MINOR_VERSION 9
41 #define LIBOFX_MICRO_VERSION 12
42 #define LIBOFX_BUILD_VERSION 0
43 #define LIBOFX_VERSION_RELEASE_STRING "0.9.12"
44
45 #ifdef IN_LIBOFX
46 # include "config.h"
47 # ifdef HAVE_GCC_VISIBILITY_EXTS
48 # pragma GCC visibility push(default)
49 # endif
50 #endif
51
52 #ifdef __cplusplus
53 extern "C" {
54 #else
55 #define true 1
56 #define false 0
57 #endif
58
59 #define OFX_ELEMENT_NAME_LENGTH 100
60 #define OFX_SVRTID2_LENGTH (36 + 1)
61 #define OFX_CHECK_NUMBER_LENGTH (12 + 1)
62 #define OFX_REFERENCE_NUMBER_LENGTH (32 + 1)
63 #define OFX_FITID_LENGTH (255 + 1)
64 #define OFX_TOKEN2_LENGTH (36 + 1)
65 #define OFX_MEMO_LENGTH (255 + 1)
66 #define OFX_FIID_LENGTH (32 + 1)
67 #define OFX_MEMO2_LENGTH (390 + 1)
68 #define OFX_BALANCE_NAME_LENGTH (32 + 1)
69 #define OFX_BALANCE_DESCRIPTION_LENGTH (80 + 1)
70 #define OFX_CURRENCY_LENGTH (3 + 1) /* In ISO-4217 format */
71 #define OFX_BANKID_LENGTH (9 + 1)
72 #define OFX_BRANCHID_LENGTH (22 + 1)
73 #define OFX_ACCTID_LENGTH (22 + 1)
74 #define OFX_ACCTKEY_LENGTH (22 + 1)
75 #define OFX_BROKERID_LENGTH (22 + 1)
76 /* Must be MAX of <BANKID>+<BRANCHID>+<ACCTID>, <ACCTID>+<ACCTKEY> and <ACCTID>+<BROKERID> */
77 #define OFX_ACCOUNT_ID_LENGTH (OFX_BANKID_LENGTH + OFX_BRANCHID_LENGTH + OFX_ACCTID_LENGTH + 1)
78 #define OFX_ACCOUNT_NAME_LENGTH 255
79 #define OFX_MARKETING_INFO_LENGTH (360 + 1)
80 #define OFX_TRANSACTION_NAME_LENGTH (96 + 1)
81 #define OFX_UNIQUE_ID_LENGTH (32 + 1)
82 #define OFX_UNIQUE_ID_TYPE_LENGTH (10 + 1)
83 #define OFX_SECNAME_LENGTH (32 + 1)
84 #define OFX_TICKER_LENGTH (32 + 1)
85 #define OFX_ORG_LENGTH (32 + 1)
86 #define OFX_FID_LENGTH (32 + 1)
87 #define OFX_USERID_LENGTH (32 + 1)
88 #define OFX_USERPASS_LENGTH (32 + 1)
89 #define OFX_URL_LENGTH (500 + 1)
90 #define OFX_APPID_LENGTH (32)
91 #define OFX_APPVER_LENGTH (32)
92 #define OFX_HEADERVERSION_LENGTH (32)
93 #define OFX_CLIENTUID_LENGTH (36 + 1)
94
95 /*
96 #define OFX_STATEMENT_CB 0;
97 #define OFX_ACCOUNT_CB 1;
98 #define OFX_TRACSACTION_CB 2;
99 #define OFX_SECURITY_CB 3;
100 #define OFX_STATUS_CB 4;
101 */
102
103 typedef void * LibofxContextPtr;
104
110 LibofxContextPtr libofx_get_new_context();
111
117 int libofx_free_context( LibofxContextPtr );
118
119 void libofx_set_dtd_dir(LibofxContextPtr libofx_context,
120 const char *s);
121
123 enum LibofxFileFormat
124 {
125 AUTODETECT,
126 OFX,
127 OFC,
128 QIF,
129 UNKNOWN,
130 LAST
131 };
132
133 struct LibofxFileFormatInfo
134 {
135 enum LibofxFileFormat format;
136 const char * format_name;
137 const char * description;
138 };
139
140
141 #ifndef OFX_AQUAMANIAC_UGLY_HACK1
142
143 const struct LibofxFileFormatInfo LibofxImportFormatList[] =
144 {
145 {AUTODETECT, "AUTODETECT", "AUTODETECT (File format will be automatically detected later)"},
146 {OFX, "OFX", "OFX (Open Financial eXchange (OFX or QFX))"},
147 {OFC, "OFC", "OFC (Microsoft Open Financial Connectivity)"},
148 {QIF, "QIF", "QIF (Intuit Quicken Interchange Format) NOT IMPLEMENTED"},
149 {LAST, "LAST", "Not a file format, meant as a loop breaking condition"}
150 };
151
152 const struct LibofxFileFormatInfo LibofxExportFormatList[] =
153 {
154 {QIF, "QIF", "QIF (Intuit Quicken Interchange Format) NOT IMPLEMENTED"},
155 {LAST, "LAST", "Not a file format, meant as a loop breaking condition"}
156 };
157
169 enum LibofxFileFormat libofx_get_file_format_from_str(const struct LibofxFileFormatInfo format_list[], const char * file_type_string);
170
182 const char * libofx_get_file_format_description(const struct LibofxFileFormatInfo format_list[], enum LibofxFileFormat file_format);
183
184 #endif
185
192 int libofx_proc_file(LibofxContextPtr libofx_context,
193 const char * p_filename,
194 enum LibofxFileFormat ftype);
195
196
209 struct OfxStatusData
210 {
215 char ofx_element_name[OFX_ELEMENT_NAME_LENGTH];
217 int ofx_element_name_valid;
218
223 int code;
224 const char* name;
225 const char* description;
226 int code_valid;
229 enum Severity
230 {
231 INFO,
232 WARN,
233 ERROR
234 } severity;
235 int severity_valid;
236
242 char* server_message;
244 int server_message_valid;
246 };
247
248
258 typedef int (*LibofxProcStatusCallback)(const struct OfxStatusData data, void * status_data);
259
271 struct OfxAccountData
272 {
273
285 char account_id[OFX_ACCOUNT_ID_LENGTH];
286
292 char account_name[OFX_ACCOUNT_NAME_LENGTH];
293 int account_id_valid;/* Use for both account_id and account_name */
294
297 enum AccountType
298 {
299 OFX_CHECKING,
300 OFX_SAVINGS,
301 OFX_MONEYMRKT,
302 OFX_CREDITLINE,
303 OFX_CMA,
304 OFX_CREDITCARD,
305 OFX_INVESTMENT
306 } account_type;
307 int account_type_valid;
308
310 char currency[OFX_CURRENCY_LENGTH];
311 int currency_valid;
312
314 char account_number[OFX_ACCTID_LENGTH];
315 int account_number_valid;
316
318 char bank_id[OFX_BANKID_LENGTH];
319 int bank_id_valid;
320
321 char broker_id[OFX_BROKERID_LENGTH];
322 int broker_id_valid;
323
324 char branch_id[OFX_BRANCHID_LENGTH];
325 int branch_id_valid;
326
327 };
328
343 typedef int (*LibofxProcAccountCallback)(const struct OfxAccountData data, void * account_data);
344
352 struct OfxSecurityData
353 {
361 char unique_id[OFX_UNIQUE_ID_LENGTH];
362 int unique_id_valid;
363
364 char unique_id_type[OFX_UNIQUE_ID_TYPE_LENGTH];
366 int unique_id_type_valid;
367
368 char secname[OFX_SECNAME_LENGTH];
369 int secname_valid;
370
376 char ticker[OFX_TICKER_LENGTH];
377 int ticker_valid;
378
379 double unitprice;
381 int unitprice_valid;
382
383 time_t date_unitprice;
384 int date_unitprice_valid;
385
388 char currency[OFX_CURRENCY_LENGTH];
389 int currency_valid;
390
391 char memo[OFX_MEMO2_LENGTH];
392 int memo_valid;
393
396 char fiid[OFX_FIID_LENGTH];
397 int fiid_valid;
398
399 };/* end struct OfxSecurityData */
400
414 typedef int (*LibofxProcSecurityCallback)(const struct OfxSecurityData data, void * security_data);
415
416 typedef enum
417 {
418 OFX_CREDIT,
419 OFX_DEBIT,
420 OFX_INT,
421 OFX_DIV,
422 OFX_FEE,
423 OFX_SRVCHG,
424 OFX_DEP,
425 OFX_ATM,
426 OFX_POS,
427 OFX_XFER,
428 OFX_CHECK,
429 OFX_PAYMENT,
430 OFX_CASH,
431 OFX_DIRECTDEP,
432 OFX_DIRECTDEBIT,
433 OFX_REPEATPMT,
434 OFX_OTHER
435 } TransactionType;
436
437 typedef enum
438 {
439 OFX_BUYDEBT,
440 OFX_BUYMF,
441 OFX_BUYOPT,
442 OFX_BUYOTHER,
443 OFX_BUYSTOCK,
444 OFX_CLOSUREOPT,
445 OFX_INCOME,
446 OFX_INVEXPENSE,
447 OFX_JRNLFUND,
448 OFX_JRNLSEC,
449 OFX_MARGININTEREST,
450 OFX_REINVEST,
451 OFX_RETOFCAP,
452 OFX_SELLDEBT,
453 OFX_SELLMF,
454 OFX_SELLOPT,
455 OFX_SELLOTHER,
456 OFX_SELLSTOCK,
457 OFX_SPLIT,
458 OFX_TRANSFER
459 } InvTransactionType;
460
461 typedef enum
462 {
463 DELETE,
465 REPLACE
467 } FiIdCorrectionAction;
468
475 struct OfxTransactionData
476 {
477
483 char account_id[OFX_ACCOUNT_ID_LENGTH];
486 struct OfxAccountData * account_ptr;
488 int account_id_valid;
489
490 TransactionType transactiontype;
491 int transactiontype_valid;
492
496 InvTransactionType invtransactiontype;
497 int invtransactiontype_valid;
498
506 double units;
507 int units_valid;
508
509 double unitprice;
511 int unitprice_valid;
512
513 double amount;
517 int amount_valid;
518
519 char fi_id[256];
522 int fi_id_valid;
523
531 char unique_id[OFX_UNIQUE_ID_LENGTH];
532 int unique_id_valid;
533 char unique_id_type[OFX_UNIQUE_ID_TYPE_LENGTH];
535 int unique_id_type_valid;
536
537 struct OfxSecurityData *security_data_ptr;
538 int security_data_valid;
539
540 time_t date_posted;
545 int date_posted_valid;
546
547 time_t date_initiated;
553 int date_initiated_valid;
554
555 time_t date_funds_available;
558 int date_funds_available_valid;
559
563 char fi_id_corrected[256];
564 int fi_id_corrected_valid;
565
568 FiIdCorrectionAction fi_id_correction_action;
569 int fi_id_correction_action_valid;
570
573 char server_transaction_id[OFX_SVRTID2_LENGTH];
574 int server_transaction_id_valid;
575
579 char check_number[OFX_CHECK_NUMBER_LENGTH];
580 int check_number_valid;
581
584 char reference_number[OFX_REFERENCE_NUMBER_LENGTH];
585 int reference_number_valid;
586
587 long int standard_industrial_code;
589 int standard_industrial_code_valid;
590
591 char payee_id[OFX_SVRTID2_LENGTH];
592 int payee_id_valid;
593
594 char name[OFX_TRANSACTION_NAME_LENGTH];
596 int name_valid;
597
598 char memo[OFX_MEMO2_LENGTH];
599 int memo_valid;
600
601 double commission;
602 int commission_valid;
603
604 double fees;
605 int fees_valid;
606
607 double oldunits; /*number of units held before stock split */
608 int oldunits_valid;
609
610 double newunits; /*number of units held after stock split */
611 int newunits_valid;
612
613
614 /*********** NOT YET COMPLETE!!! *********************/
615 };
616
626 typedef int (*LibofxProcTransactionCallback)(const struct OfxTransactionData data, void * transaction_data);
627
637 struct OfxStatementData
638 {
639
647 char currency[OFX_CURRENCY_LENGTH];
648 int currency_valid;
649
650 char account_id[OFX_ACCOUNT_ID_LENGTH];
652 struct OfxAccountData * account_ptr;
654 int account_id_valid;
655
658 double ledger_balance;
659 int ledger_balance_valid;
660
661 time_t ledger_balance_date;
662 int ledger_balance_date_valid;
663
669 double available_balance;
672 int available_balance_valid;
673
674 time_t available_balance_date;
675 int available_balance_date_valid;
676
681 time_t date_start;
682 int date_start_valid;
683
688 time_t date_end;
689 int date_end_valid;
690
693 char marketing_info[OFX_MARKETING_INFO_LENGTH];
694 int marketing_info_valid;
695 };
696
704 typedef int (*LibofxProcStatementCallback)(const struct OfxStatementData data, void * statement_data);
705
709 struct OfxCurrency
710 {
711 char currency[OFX_CURRENCY_LENGTH];
712 double exchange_rate;
713 int must_convert;
714 };
715
716
723 void ofx_set_status_cb(LibofxContextPtr ctx,
724 LibofxProcStatusCallback cb,
725 void *user_data);
726
733 void ofx_set_account_cb(LibofxContextPtr ctx,
734 LibofxProcAccountCallback cb,
735 void *user_data);
736
743 void ofx_set_security_cb(LibofxContextPtr ctx,
744 LibofxProcSecurityCallback cb,
745 void *user_data);
746
753 void ofx_set_transaction_cb(LibofxContextPtr ctx,
754 LibofxProcTransactionCallback cb,
755 void *user_data);
756
763 void ofx_set_statement_cb(LibofxContextPtr ctx,
764 LibofxProcStatementCallback cb,
765 void *user_data);
766
767
771 int libofx_proc_buffer(LibofxContextPtr ctx,
772 const char *s, unsigned int size);
773
774
775 /* **************************************** */
776
782
786 struct OfxFiServiceInfo
787 {
788 char fid[OFX_FID_LENGTH];
789 char org[OFX_ORG_LENGTH];
790 char url[OFX_URL_LENGTH];
791 int accountlist;
792 int statements;
793 int billpay;
794 int investments;
795 };
796
806 struct OfxFiLogin
807 {
808 char fid[OFX_FID_LENGTH];
809 char org[OFX_ORG_LENGTH];
810 char userid[OFX_USERID_LENGTH];
811 char userpass[OFX_USERPASS_LENGTH];
812 char header_version[OFX_HEADERVERSION_LENGTH];
813 char appid[OFX_APPID_LENGTH];
814 char appver[OFX_APPVER_LENGTH];
815 char clientuid[OFX_CLIENTUID_LENGTH];
816 };
817
818 #define OFX_AMOUNT_LENGTH (32 + 1)
819 #define OFX_PAYACCT_LENGTH (32 + 1)
820 #define OFX_STATE_LENGTH (5 + 1)
821 #define OFX_POSTALCODE_LENGTH (11 + 1)
822 #define OFX_NAME_LENGTH (32 + 1)
823
824 struct OfxPayment
825 {
826 char amount[OFX_AMOUNT_LENGTH];
827 char account[OFX_PAYACCT_LENGTH];
828 char datedue[9];
829 char memo[OFX_MEMO_LENGTH];
830 };
831
832 struct OfxPayee
833 {
834 char name[OFX_NAME_LENGTH];
835 char address1[OFX_NAME_LENGTH];
836 char city[OFX_NAME_LENGTH];
837 char state[OFX_STATE_LENGTH];
838 char postalcode[OFX_POSTALCODE_LENGTH];
839 char phone[OFX_NAME_LENGTH];
840 };
841
853 char* libofx_request_statement( const struct OfxFiLogin* fi, const struct OfxAccountData* account, time_t date_from );
854
865 char* libofx_request_accountinfo( const struct OfxFiLogin* login );
866
867 char* libofx_request_payment( const struct OfxFiLogin* login, const struct OfxAccountData* account, const struct OfxPayee* payee, const struct OfxPayment* payment );
868
869 char* libofx_request_payment_status( const struct OfxFiLogin* login, const char* transactionid );
870
872
873 extern int ofx_PARSER_msg;
874 extern int ofx_DEBUG_msg;
875 extern int ofx_DEBUG1_msg;
876 extern int ofx_DEBUG2_msg;
877 extern int ofx_DEBUG3_msg;
878 extern int ofx_DEBUG4_msg;
879 extern int ofx_DEBUG5_msg;
880 extern int ofx_STATUS_msg;
881 extern int ofx_INFO_msg;
882 extern int ofx_WARNING_msg;
883 extern int ofx_ERROR_msg;
884 extern int ofx_show_position;
886 #ifdef __cplusplus
887 } // end of extern "C"
888 #endif
889
890 #if defined(HAVE_GCC_VISIBILITY_EXTS) && defined(IN_LIBOFX)
891 # pragma GCC visibility pop
892 #endif
893
894 #endif // end of LIBOFX_H
OfxTransactionData::date_posted
time_t date_posted
Definition: inc/libofx.h:540
OfxStatementData::ledger_balance_date
time_t ledger_balance_date
Definition: inc/libofx.h:661
OFX_BUYMF
Definition: libofx-0.9.12/inc/libofx.h:440
OfxAccountData
An abstraction of an account.
Definition: inc/libofx.h:271
OfxPayee
Definition: inc/libofx.h:832
libofx_proc_file
int libofx_proc_file(LibofxContextPtr libofx_context, const char *p_filename, enum LibofxFileFormat ftype)
libofx_proc_file is the entry point of the library.
Definition: file_preproc.cpp:67
QIF
Definition: libofx-0.9.12/inc/libofx.h:128
OfxStatusData::code_valid
int code_valid
Definition: inc/libofx.h:226
OFX_SELLOPT
Definition: libofx-0.9.12/inc/libofx.h:454
DELETE
Definition: libofx-0.9.12/inc/libofx.h:463
InvTransactionType
InvTransactionType
Definition: libofx-0.9.12/inc/libofx.h:437
libofx_get_new_context
LibofxContextPtr libofx_get_new_context()
Initialise the library and return a new context.
Definition: context.cpp:153
OfxStatusData::Severity
Severity
Definition: inc/libofx.h:229
OFX_DEP
Definition: libofx-0.9.12/inc/libofx.h:424
LibofxFileFormatInfo
Definition: inc/libofx.h:133
LibofxFileFormatInfo::format
enum LibofxFileFormat format
Definition: inc/libofx.h:135
OfxTransactionData::reference_number
char reference_number[OFX_REFERENCE_NUMBER_LENGTH]
Definition: inc/libofx.h:584
OFX_DEBIT
Definition: libofx-0.9.12/inc/libofx.h:419
OFX_BUYDEBT
Definition: libofx-0.9.12/inc/libofx.h:439
REPLACE
Definition: libofx-0.9.12/inc/libofx.h:465
InvTransactionType
InvTransactionType
Definition: inc/libofx.h:437
ofx_set_security_cb
void ofx_set_security_cb(LibofxContextPtr ctx, LibofxProcSecurityCallback cb, void *user_data)
Definition: context.cpp:195
OfxStatementData::available_balance
double available_balance
Definition: inc/libofx.h:669
ofx_set_transaction_cb
void ofx_set_transaction_cb(LibofxContextPtr ctx, LibofxProcTransactionCallback cb, void *user_data)
Definition: context.cpp:204
TransactionType
TransactionType
Definition: libofx-0.9.12/inc/libofx.h:416
OfxTransactionData::units
double units
Definition: inc/libofx.h:506
LibofxProcAccountCallback
int(* LibofxProcAccountCallback)(const struct OfxAccountData data, void *account_data)
The callback function for the OfxAccountData stucture.
Definition: libofx-0.9.12/inc/libofx.h:343
OfxTransactionData::unique_id
char unique_id[OFX_UNIQUE_ID_LENGTH]
Definition: inc/libofx.h:531
OfxAccountData::account_id
char account_id[OFX_ACCOUNT_ID_LENGTH]
Definition: inc/libofx.h:285
LibofxFileFormatInfo::description
const char * description
Definition: inc/libofx.h:137
OfxCurrency::exchange_rate
double exchange_rate
Definition: inc/libofx.h:712
AUTODETECT
Definition: libofx-0.9.12/inc/libofx.h:125
OfxStatusData::description
const char * description
Definition: inc/libofx.h:225
ofx_DEBUG3_msg
int ofx_DEBUG3_msg
Definition: messages.cpp:34
OfxTransactionData::fi_id_corrected
char fi_id_corrected[256]
Definition: inc/libofx.h:563
OfxAccountData::OFX_SAVINGS
Definition: inc/libofx.h:300
OFX_CLOSUREOPT
Definition: libofx-0.9.12/inc/libofx.h:444
OFX_BUYOTHER
Definition: libofx-0.9.12/inc/libofx.h:442
ofx_DEBUG_msg
int ofx_DEBUG_msg
Definition: messages.cpp:31
OfxAccountData::currency
char currency[OFX_CURRENCY_LENGTH]
Definition: inc/libofx.h:310
OfxTransactionData::check_number
char check_number[OFX_CHECK_NUMBER_LENGTH]
Definition: inc/libofx.h:579
OfxStatementData::date_start
time_t date_start
Definition: inc/libofx.h:681
OfxStatusData::ERROR
Definition: inc/libofx.h:233
OfxStatementData::date_end
time_t date_end
Definition: inc/libofx.h:688
OfxFiServiceInfo::accountlist
int accountlist
Definition: inc/libofx.h:791
libofx_proc_buffer
int libofx_proc_buffer(LibofxContextPtr ctx, const char *s, unsigned int size)
OfxAccountData::OFX_CREDITCARD
Definition: inc/libofx.h:304
OfxTransactionData::transactiontype_valid
int transactiontype_valid
Definition: inc/libofx.h:491
OfxTransactionData::name
char name[OFX_TRANSACTION_NAME_LENGTH]
Definition: inc/libofx.h:594
OFX_INVEXPENSE
Definition: libofx-0.9.12/inc/libofx.h:446
LibofxProcTransactionCallback
int(* LibofxProcTransactionCallback)(const struct OfxTransactionData data, void *transaction_data)
The callback function for the OfxTransactionData stucture.
Definition: libofx-0.9.12/inc/libofx.h:626
OfxTransactionData::fi_id
char fi_id[256]
Definition: inc/libofx.h:519
OfxStatusData::INFO
Definition: inc/libofx.h:231
ofx_show_position
int ofx_show_position
Definition: messages.cpp:41
OfxTransactionData::commission
double commission
Definition: inc/libofx.h:601
OfxFiServiceInfo::investments
int investments
Definition: inc/libofx.h:794
OfxStatementData::marketing_info
char marketing_info[OFX_MARKETING_INFO_LENGTH]
Definition: inc/libofx.h:693
OfxTransactionData::memo
char memo[OFX_MEMO2_LENGTH]
Definition: inc/libofx.h:598
OfxTransactionData::fi_id_correction_action
FiIdCorrectionAction fi_id_correction_action
Definition: inc/libofx.h:568
OFC
Definition: libofx-0.9.12/inc/libofx.h:127
OfxFiServiceInfo::billpay
int billpay
Definition: inc/libofx.h:793
OFX_SELLMF
Definition: libofx-0.9.12/inc/libofx.h:453
OfxSecurityData::currency
char currency[OFX_CURRENCY_LENGTH]
Definition: inc/libofx.h:388
ofx_DEBUG4_msg
int ofx_DEBUG4_msg
Definition: messages.cpp:35
OfxStatusData::WARN
Definition: inc/libofx.h:232
ofx_ERROR_msg
int ofx_ERROR_msg
Definition: messages.cpp:40
ofx_set_account_cb
void ofx_set_account_cb(LibofxContextPtr ctx, LibofxProcAccountCallback cb, void *user_data)
Definition: context.cpp:186
OfxPayment
Definition: inc/libofx.h:824
OFX_CASH
Definition: libofx-0.9.12/inc/libofx.h:430
OfxStatusData::code
int code
Definition: inc/libofx.h:223
libofx_get_file_format_from_str
enum LibofxFileFormat libofx_get_file_format_from_str(const struct LibofxFileFormatInfo format_list[], const char *file_type_string)
libofx_get_file_type returns a proper enum from a file type string.
Definition: file_preproc.cpp:54
OfxTransactionData::standard_industrial_code
long int standard_industrial_code
Definition: inc/libofx.h:587
OfxStatementData::account_id
char account_id[OFX_ACCOUNT_ID_LENGTH]
Definition: inc/libofx.h:650
OfxSecurityData::memo
char memo[OFX_MEMO2_LENGTH]
Definition: inc/libofx.h:391
OFX_OTHER
Definition: libofx-0.9.12/inc/libofx.h:434
OFX_REPEATPMT
Definition: libofx-0.9.12/inc/libofx.h:433
OFX_CHECK
Definition: libofx-0.9.12/inc/libofx.h:428
OfxSecurityData::fiid
char fiid[OFX_FIID_LENGTH]
Definition: inc/libofx.h:396
ofx_set_statement_cb
void ofx_set_statement_cb(LibofxContextPtr ctx, LibofxProcStatementCallback cb, void *user_data)
Definition: context.cpp:213
OFX_INT
Definition: libofx-0.9.12/inc/libofx.h:420
OFX_SELLSTOCK
Definition: libofx-0.9.12/inc/libofx.h:456
OfxTransactionData::date_initiated
time_t date_initiated
Definition: inc/libofx.h:547
OfxCurrency::currency
char currency[OFX_CURRENCY_LENGTH]
Definition: inc/libofx.h:711
OfxTransactionData::account_id
char account_id[OFX_ACCOUNT_ID_LENGTH]
Definition: inc/libofx.h:483
libofx_request_statement
char * libofx_request_statement(const struct OfxFiLogin *fi, const struct OfxAccountData *account, time_t date_from)
Creates an OFX statement request in string form.
OFX_DIV
Definition: libofx-0.9.12/inc/libofx.h:421
OfxSecurityData::unique_id
char unique_id[OFX_UNIQUE_ID_LENGTH]
Definition: inc/libofx.h:361
OfxAccountData::account_name
char account_name[OFX_ACCOUNT_NAME_LENGTH]
Definition: inc/libofx.h:292
OfxAccountData::OFX_MONEYMRKT
Definition: inc/libofx.h:301
OfxTransactionData::unitprice
double unitprice
Definition: inc/libofx.h:509
FiIdCorrectionAction
FiIdCorrectionAction
Definition: inc/libofx.h:461
FiIdCorrectionAction
FiIdCorrectionAction
Definition: libofx-0.9.12/inc/libofx.h:461
OFX_REINVEST
Definition: libofx-0.9.12/inc/libofx.h:450
OfxStatusData::server_message
char * server_message
Definition: inc/libofx.h:242
OfxTransactionData::account_ptr
struct OfxAccountData * account_ptr
Definition: inc/libofx.h:486
ofx_WARNING_msg
int ofx_WARNING_msg
Definition: messages.cpp:39
OfxSecurityData::date_unitprice
time_t date_unitprice
Definition: inc/libofx.h:383
TransactionType
TransactionType
Definition: inc/libofx.h:416
OfxTransactionData::server_transaction_id
char server_transaction_id[OFX_SVRTID2_LENGTH]
Definition: inc/libofx.h:573
UNKNOWN
Definition: libofx-0.9.12/inc/libofx.h:129
OfxStatementData::account_ptr
struct OfxAccountData * account_ptr
Definition: inc/libofx.h:652
libofx_get_file_format_description
const char * libofx_get_file_format_description(const struct LibofxFileFormatInfo format_list[], enum LibofxFileFormat file_format)
get_file_format_description returns a string description of a LibofxFileType.
Definition: file_preproc.cpp:37
OFX_INCOME
Definition: libofx-0.9.12/inc/libofx.h:445
OFX_ATM
Definition: libofx-0.9.12/inc/libofx.h:425
OfxAccountData::AccountType
AccountType
Definition: inc/libofx.h:297
OfxAccountData::bank_id
char bank_id[OFX_BANKID_LENGTH]
Definition: inc/libofx.h:318
LibofxProcStatementCallback
int(* LibofxProcStatementCallback)(const struct OfxStatementData data, void *statement_data)
The callback function for the OfxStatementData stucture.
Definition: libofx-0.9.12/inc/libofx.h:704
OFX_SRVCHG
Definition: libofx-0.9.12/inc/libofx.h:423
OFX_FEE
Definition: libofx-0.9.12/inc/libofx.h:422
OFX_POS
Definition: libofx-0.9.12/inc/libofx.h:426
OfxTransactionData::amount
double amount
Definition: inc/libofx.h:513
OfxStatusData
An abstraction of an OFX STATUS element.
Definition: inc/libofx.h:209
OFX
Definition: libofx-0.9.12/inc/libofx.h:126
OFX_BUYOPT
Definition: libofx-0.9.12/inc/libofx.h:441
ofx_DEBUG2_msg
int ofx_DEBUG2_msg
Definition: messages.cpp:33
OfxSecurityData::unitprice
double unitprice
Definition: inc/libofx.h:379
OfxSecurityData::unique_id_type
char unique_id_type[OFX_UNIQUE_ID_TYPE_LENGTH]
Definition: inc/libofx.h:364
LAST
Definition: libofx-0.9.12/inc/libofx.h:130
OFX_RETOFCAP
Definition: libofx-0.9.12/inc/libofx.h:451
libofx_free_context
int libofx_free_context(LibofxContextPtr)
Free all ressources used by this context.
Definition: context.cpp:158
ofx_set_status_cb
void ofx_set_status_cb(LibofxContextPtr ctx, LibofxProcStatusCallback cb, void *user_data)
Definition: context.cpp:178
OFX_BUYSTOCK
Definition: libofx-0.9.12/inc/libofx.h:443
libofx_request_accountinfo
char * libofx_request_accountinfo(const struct OfxFiLogin *login)
Creates an OFX account info (list) request in string form.
ofx_STATUS_msg
int ofx_STATUS_msg
Definition: messages.cpp:37
LibofxFileFormatInfo::format_name
const char * format_name
Definition: inc/libofx.h:136
ofx_PARSER_msg
int ofx_PARSER_msg
Definition: messages.cpp:30
OFX_TRANSFER
Definition: libofx-0.9.12/inc/libofx.h:458
OfxStatementData::available_balance_date_valid
int available_balance_date_valid
Definition: inc/libofx.h:675
OfxSecurityData::ticker
char ticker[OFX_TICKER_LENGTH]
Definition: inc/libofx.h:376
OfxTransactionData::security_data_valid
int security_data_valid
Definition: inc/libofx.h:538
OfxFiServiceInfo
Information returned by the OFX Partner Server about a financial institution.
Definition: inc/libofx.h:786
OfxTransactionData::payee_id
char payee_id[OFX_SVRTID2_LENGTH]
Definition: inc/libofx.h:591
OFX_SELLOTHER
Definition: libofx-0.9.12/inc/libofx.h:455
OFX_XFER
Definition: libofx-0.9.12/inc/libofx.h:427
OfxSecurityData
An abstraction of a security, such as a stock, mutual fund, etc.
Definition: inc/libofx.h:352
OFX_CREDIT
Definition: libofx-0.9.12/inc/libofx.h:418
OfxStatusData::ofx_element_name_valid
int ofx_element_name_valid
Definition: inc/libofx.h:217
ofx_INFO_msg
int ofx_INFO_msg
Definition: messages.cpp:38
OFX_DIRECTDEP
Definition: libofx-0.9.12/inc/libofx.h:431
ofx_DEBUG1_msg
int ofx_DEBUG1_msg
Definition: messages.cpp:32
LibofxProcStatusCallback
int(* LibofxProcStatusCallback)(const struct OfxStatusData data, void *status_data)
The callback function for the OfxStatusData stucture.
Definition: libofx-0.9.12/inc/libofx.h:258
OFX_DIRECTDEBIT
Definition: libofx-0.9.12/inc/libofx.h:432
OfxTransactionData::fees
double fees
Definition: inc/libofx.h:604
OfxTransactionData
An abstraction of a transaction in an account.
Definition: inc/libofx.h:475
ofx_DEBUG5_msg
int ofx_DEBUG5_msg
Definition: messages.cpp:36
OfxCurrency::must_convert
int must_convert
Definition: inc/libofx.h:713
OfxTransactionData::date_funds_available
time_t date_funds_available
Definition: inc/libofx.h:555
OfxCurrency
NOT YET SUPPORTED.
Definition: inc/libofx.h:709
LibofxFileFormat
LibofxFileFormat
Definition: inc/libofx.h:123
OfxAccountData::OFX_CMA
Definition: inc/libofx.h:303
OfxStatusData::name
const char * name
Definition: inc/libofx.h:224
OfxAccountData::account_number
char account_number[OFX_ACCTID_LENGTH]
Definition: inc/libofx.h:314
LibofxProcSecurityCallback
int(* LibofxProcSecurityCallback)(const struct OfxSecurityData data, void *security_data)
The callback function for the OfxSecurityData stucture.
Definition: libofx-0.9.12/inc/libofx.h:414
OFX_JRNLSEC
Definition: libofx-0.9.12/inc/libofx.h:448
OfxAccountData::OFX_CREDITLINE
Definition: inc/libofx.h:302
OfxTransactionData::unique_id_type
char unique_id_type[OFX_UNIQUE_ID_TYPE_LENGTH]
Definition: inc/libofx.h:533
OfxStatementData::currency
char currency[OFX_CURRENCY_LENGTH]
Definition: inc/libofx.h:647
OfxFiServiceInfo::statements
int statements
Definition: inc/libofx.h:792
OfxAccountData::OFX_INVESTMENT
Definition: inc/libofx.h:305
OfxAccountData::OFX_CHECKING
Definition: inc/libofx.h:299
OfxStatementData::ledger_balance
double ledger_balance
Definition: inc/libofx.h:658
OFX_JRNLFUND
Definition: libofx-0.9.12/inc/libofx.h:447
OFX_MARGININTEREST
Definition: libofx-0.9.12/inc/libofx.h:449
OfxStatementData
An abstraction of an account statement.
Definition: inc/libofx.h:637
OFX_SPLIT
Definition: libofx-0.9.12/inc/libofx.h:457
OFX_SELLDEBT
Definition: libofx-0.9.12/inc/libofx.h:452
OfxSecurityData::secname
char secname[OFX_SECNAME_LENGTH]
Definition: inc/libofx.h:368
OFX_PAYMENT
Definition: libofx-0.9.12/inc/libofx.h:429
OfxFiLogin
Information sufficient to log into an financial institution.
Definition: inc/libofx.h:806