{"_id":"5591ad2cc671980d00543dd8","excerpt":"","hidden":false,"sync_unique":"","title":"Getting Started with Investor API","type":"basic","createdAt":"2015-06-29T20:40:12.890Z","githubsync":"","link_url":"","project":"543de77431ca981a00a700ec","version":"55819c76a5474a0d00d945db","api":{"params":[],"results":{"codes":[]},"settings":"","url":"","auth":"required"},"body":"[block:callout]\n{\n  \"type\": \"warning\",\n  \"title\": \"API v1 is no longer available.\",\n  \"body\": \"As of August 17th, Version 1 of our API is no longer available. Please be sure to use API version 2 for access to Funding Circles API\"\n}\n[/block]\nFunding Circle’s API was built using [REST](https://en.wikipedia.org/wiki/Representational_state_transfer) in order to ensure fast and efficient access to your data. We’ve created multiple endpoints allowing you to see information about your holdings, pending orders, portfolio and transactions, as well as allowing you to view current listings.  Our API will also allow you to purchase both whole loans as well as fractional loans depending on your account type. Results from API calls are sent back via [JSON](https://en.wikipedia.org/wiki/JSON).\n\nThe base url to hit for accessing the API is: https://investor-api.fundingcircle.us/api/v2, for testing you can use our sandbox environment: https://investor-api.fc-sandbox.us/api/v2.\n\nTo sign up for API v2, please see the [authentication page](http://developers.fundingcircle.us/docs/getting-started) for more information after logging into the Investor Portal.\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"API Structure\"\n}\n[/block]\nThe API generally uses GET methods to retrieve information about loans, holdings, transactions, and your portfolio at varying degrees of granularity. The API also contains a POST method to create orders for both fractional and whole loans. \n\nWhen making API calls the result will typically include sub-endpoints if any are available. For example, the /holdings endpoint has one sub-endpoint (/holdings/:id), which itself has two other sub-endpoints (/holdings/:id/payments and /holdings/:id/financials). Calling /holdings/:id will return links for both the payments and the financial endpoints. \n\nThe structure of our API is below:\n[(view large version)](https://drive.google.com/a/fundingcircle.com/file/d/0B5vxHRUB-MjnVFd0aFJ4dmxYTnM/view?usp=sharing) \n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/nZRLZHSTeeh95Wcno1nN_Blank%20Flowchart%20-%20API%20Documentation.png\",\n        \"Blank Flowchart - API Documentation.png\",\n        \"1725\",\n        \"3788\",\n        \"#b2b2b2\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\n\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"Endpoints\"\n}\n[/block]\nGET [/listings](http://developers.fundingcircle.us/docs/listings#listings)\nGET [/listings/:id](http://developers.fundingcircle.us/docs/listings#listingsid)\nGET [/listings/:id/financials](http://developers.fundingcircle.us/docs/listings#listingsidfinancials)\nGET [/listings/:id/payments](http://developers.fundingcircle.us/docs/listings#listingsidpayments)\nGET [/holdings](http://developers.fundingcircle.us/docs/get-my-holdings#holdings)\nGET [/holdings/:id](http://developers.fundingcircle.us/docs/get-my-holdings#holdingsid)\nGET[ /holdings/:id/financials](http://developers.fundingcircle.us/docs/get-my-holdings#holdingsidfinancials)\nGET [/transactions](http://developers.fundingcircle.us/docs/get-transactions)\nGET [/portfolio](http://developers.fundingcircle.us/docs/get-portfolio-1)\nGET [/orders](http://developers.fundingcircle.us/docs/get-pending-orders)\nPOST [/orders](http://developers.fundingcircle.us/docs/post-orders)\nGET [/filters](http://developers.fundingcircle.us/docs/get-filters)\nGET [/filters/risk_bands](http://developers.fundingcircle.us/docs/get-filters#risk-bands)\nGET [/filters/terms](http://developers.fundingcircle.us/docs/get-filters#terms) \n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"Notes about formats\"\n}\n[/block]\nAll keys that are date fields will end with either '_date' or '_at'. These will be formatted as ISO-8601 \nNOTE: In sandbox, times may not be in UTC\n\nAll keys that are id's will end with '_id' and are formatted as UUID.\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"Read Only Access\"\n}\n[/block]\nFor investors who need to give access to third parties (for example, to compile reports) we offer a read only access mode. This will enable access for users who cannot send in orders or purchase loans, but can only view the data in your account. \n\nTo set this up, go to the API Management page of your investor portal, and click on Read Only Access at the top of the page.\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"Migrating from Sandbox to Production\"\n}\n[/block]\nWhen you are done testing in Sandbox, you can easily move your code to production. In order to do this you will need to enable APIv2 Access on your Production Account (from the API management page). \n[block:callout]\n{\n  \"type\": \"warning\",\n  \"title\": \"Different credentials\",\n  \"body\": \"You will not be able to use your sandbox credentials (API ID and Password) in production. You will need to repeat the process in production of enabling APIv2 and using the new API ID and Password to get a bearer token.\"\n}\n[/block]\nChange the API ID and Password to the newly generated Production versions of the  API ID and Password. \n\nChange the login URL to: http://investor-api.fundingcircle.us/api/v2\n(Note you have only changed **.fc-sandbox.us** to **.fundingcircle.us**)\n\nNow you can get a bearer token and continue using your code in our production API","user":"557b54fb9670ce0d0071b7bd","__v":26,"category":"55819c76a5474a0d00d945dc","slug":"authentication","updates":[],"link_external":false,"order":0,"childrenPages":[]}

Getting Started with Investor API


[block:callout] { "type": "warning", "title": "API v1 is no longer available.", "body": "As of August 17th, Version 1 of our API is no longer available. Please be sure to use API version 2 for access to Funding Circles API" } [/block] Funding Circle’s API was built using [REST](https://en.wikipedia.org/wiki/Representational_state_transfer) in order to ensure fast and efficient access to your data. We’ve created multiple endpoints allowing you to see information about your holdings, pending orders, portfolio and transactions, as well as allowing you to view current listings. Our API will also allow you to purchase both whole loans as well as fractional loans depending on your account type. Results from API calls are sent back via [JSON](https://en.wikipedia.org/wiki/JSON). The base url to hit for accessing the API is: https://investor-api.fundingcircle.us/api/v2, for testing you can use our sandbox environment: https://investor-api.fc-sandbox.us/api/v2. To sign up for API v2, please see the [authentication page](http://developers.fundingcircle.us/docs/getting-started) for more information after logging into the Investor Portal. [block:api-header] { "type": "basic", "title": "API Structure" } [/block] The API generally uses GET methods to retrieve information about loans, holdings, transactions, and your portfolio at varying degrees of granularity. The API also contains a POST method to create orders for both fractional and whole loans. When making API calls the result will typically include sub-endpoints if any are available. For example, the /holdings endpoint has one sub-endpoint (/holdings/:id), which itself has two other sub-endpoints (/holdings/:id/payments and /holdings/:id/financials). Calling /holdings/:id will return links for both the payments and the financial endpoints. The structure of our API is below: [(view large version)](https://drive.google.com/a/fundingcircle.com/file/d/0B5vxHRUB-MjnVFd0aFJ4dmxYTnM/view?usp=sharing) [block:image] { "images": [ { "image": [ "https://files.readme.io/nZRLZHSTeeh95Wcno1nN_Blank%20Flowchart%20-%20API%20Documentation.png", "Blank Flowchart - API Documentation.png", "1725", "3788", "#b2b2b2", "" ] } ] } [/block] [block:api-header] { "type": "basic", "title": "Endpoints" } [/block] GET [/listings](http://developers.fundingcircle.us/docs/listings#listings) GET [/listings/:id](http://developers.fundingcircle.us/docs/listings#listingsid) GET [/listings/:id/financials](http://developers.fundingcircle.us/docs/listings#listingsidfinancials) GET [/listings/:id/payments](http://developers.fundingcircle.us/docs/listings#listingsidpayments) GET [/holdings](http://developers.fundingcircle.us/docs/get-my-holdings#holdings) GET [/holdings/:id](http://developers.fundingcircle.us/docs/get-my-holdings#holdingsid) GET[ /holdings/:id/financials](http://developers.fundingcircle.us/docs/get-my-holdings#holdingsidfinancials) GET [/transactions](http://developers.fundingcircle.us/docs/get-transactions) GET [/portfolio](http://developers.fundingcircle.us/docs/get-portfolio-1) GET [/orders](http://developers.fundingcircle.us/docs/get-pending-orders) POST [/orders](http://developers.fundingcircle.us/docs/post-orders) GET [/filters](http://developers.fundingcircle.us/docs/get-filters) GET [/filters/risk_bands](http://developers.fundingcircle.us/docs/get-filters#risk-bands) GET [/filters/terms](http://developers.fundingcircle.us/docs/get-filters#terms) [block:api-header] { "type": "basic", "title": "Notes about formats" } [/block] All keys that are date fields will end with either '_date' or '_at'. These will be formatted as ISO-8601 NOTE: In sandbox, times may not be in UTC All keys that are id's will end with '_id' and are formatted as UUID. [block:api-header] { "type": "basic", "title": "Read Only Access" } [/block] For investors who need to give access to third parties (for example, to compile reports) we offer a read only access mode. This will enable access for users who cannot send in orders or purchase loans, but can only view the data in your account. To set this up, go to the API Management page of your investor portal, and click on Read Only Access at the top of the page. [block:api-header] { "type": "basic", "title": "Migrating from Sandbox to Production" } [/block] When you are done testing in Sandbox, you can easily move your code to production. In order to do this you will need to enable APIv2 Access on your Production Account (from the API management page). [block:callout] { "type": "warning", "title": "Different credentials", "body": "You will not be able to use your sandbox credentials (API ID and Password) in production. You will need to repeat the process in production of enabling APIv2 and using the new API ID and Password to get a bearer token." } [/block] Change the API ID and Password to the newly generated Production versions of the API ID and Password. Change the login URL to: http://investor-api.fundingcircle.us/api/v2 (Note you have only changed **.fc-sandbox.us** to **.fundingcircle.us**) Now you can get a bearer token and continue using your code in our production API