T2 - Documents Endpoints

/api/partner/1.0/t2/documents/getList (POST)

Endpoint authentication

When adopting OAuth 2.0 as an authentication method, the below security requirements are needed in order to trigger this endpoint:

  • The user must fulfill the below security roles requirements; if he fails to obtain access to all the necessary security roles, an error 403: Insufficient privileges to execute this request is returned:

    • The user must acquire access to the following security role:

      • Tax – Access T2 Product

    • When the user has access to the below security role, he is able to use the property customReturnManagerFilterIds in the request body to filter the results based on the custom filter Id(s) provided. In case the user does not have access to the said security role and he tries to apply a filter, an error 403: Insufficient privileges to execute this request is returned:

      • Tax – Return Manager – Custom Filters - Apply

  • This endpoint validates against the user’s contact security and document visibility. If the user does not have access to a given document or to the contact associated to this document, the document will not be included in the response body.

Endpoint description

Returns a list of documents with all metadata available in the return manager for a specific year of the T2 product.

Note: Requesting the list of documents for the latest taxation period displayed in the return manager will return the list of documents for all years supported by this version. For example, if the last year currently displayed in the return manager supports 2022 and later, this means that getting the list of documents for 2023 will return the list of documents present in the return manager for the 2022 and later period.

Model

{

"cursor": "string",

"search": "string",

"perPage": 0,

"sortColumn": "string",

"sortOrder": "string",

"filters": {},

"excludePlanner": true,

"customReturnManagerFilterIds": [

0

]

}

Properties

cursor: Optional parameter used to navigate between the pages of the resulting response. The "nextCursor" and "prevCursor" parameters, returned in the response of this endpoint, provide the value to use for the cursor parameter.

When this parameter is included in a request, the other parameters will be ignored.

search: Optional parameter used for filtering out results based on a string search.

perPage: Optional parameter that controls the number of results per page (1-500). If you do not include the per page parameter, the application will default to 500.

sortColumn: Optional parameter to sort on a specific columnID. The list of columnIDs can be viewed here. If you do not include the sortColumn parameter, the application will sort using the date modified column.

sortOrder: Optional parameter used to sort in ascending or descending order. If you do not include the sortOrder parameter, the application will default to ascending order.

filters: Optional parameter used for filtering out results based on column(s) value(s). One or more columnIDs must be provided with values to use. The list of columnIDs is available here.

excludePlanner: Optional parameter used to include or exclude planner files. If you do not include the excludePlanner parameter, the application will include the planner documents by default.

customReturnManagerFilterIds: Optional parameter used for filtering out results based on a custom filter. The ID of the custom filter must be provided, it can be found in the URL of each custom filter under “Settings/Tax/Custom Diagnostics & Custom Filters”

Examples

Example of getting a list of returns where the reviewer ID is 1:

Request URL

https://mysite.cchifirm.ca/taxcan/api/partner/1.0/t2/documents/getList?returnManagerYear=2023

Request body

{

"perPage": 500,

"sortColumn": "date_modified",

"sortOrder": "Desc",

"filters": {

"reviewer_id": [

1

]

}

}

Response body

{

"result": [

{

"taxationStartDate": "2023-01-01",

"taxationEndDate": "2023-12-31",

"taxpayers": [

{

"name": "Kreiger, Stoltenberg and Torphy",

"businessNumber": "#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "JS-177176138",

"efileStatuses": {

"t2": "Not Eligible",

"mr69": "Not Applicable",

"t2054": "Not Applicable",

"sch89": "Not Eligible",

"t2attachment": "Not Applicable",

"t106attachment": "Not Applicable",

"t1134attachment": "Not Applicable",

"t1135attachment": "Not Applicable",

"sch89attachment": "Not Applicable",

"t2054attachment": "Not Applicable",

"at1": "Not Applicable",

"co17": "Not Applicable",

"t1135": "Not Applicable",

"t1134": "Not Applicable",

"t106": "Not Applicable",

"rc4649": "Not Applicable",

"authorization": "Not Applicable",

"cancellation": "Not Applicable"

},

"eSignatureStatuses": {

"t183": "0",

"co1000": "0"

},

"preparer": null,

"reviewer": {

"userId": 1,

"firstName": "Marc",

"lastName": "Lacasse"

},

"partner": null,

"contactGroup": {

"id": 60,

"name": "Pharmacy"

},

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"

}],

"documentId": "9d8c3443-fbe5-43d1-bb3f-d3e5eba79671",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "WebAPI Created",

"labelId": "46918af7-78dc-49bc-9a9d-c82218c18ba6",

"lastModificationTimestamp": "2024-04-22T17:38:24Z",

“lastModificationActionType”: "printed_return"

}],

"prevCursor": null,

"nextCursor": null,

"errors": []

}

Example of getting a list of returns where the date modified is between two timestamps:

Request URL

https://mysite.cchifirm.ca/taxcan/api/partner/1.0/t2/documents/getList?returnManagerYear=2023

Request body

{

"perPage": 500,

"sortColumn": "date_modified",

"sortOrder": "Desc",

"filters": {

"date_modified": [

"2024-04-21T01:11:45Z",

"2024-04-23T01:11:45Z"

]

}

}

Response body

{

"result": [

{

"taxationStartDate": "2023-01-01",

"taxationEndDate": "2023-12-31",

"taxpayers": [

{

"name": "Kreiger, Stoltenberg and Torphy",

"businessNumber": "#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "JS-177176138",

"efileStatuses": {

"t2": "Not Eligible",

"mr69": "Not Applicable",

"t2054": "Not Applicable",

"sch89": "Not Eligible",

"t2attachment": "Not Applicable ",

"t106attachment": "Not Applicable",

"t1134attachment": "Not Applicable",

"t1135attachment": "Not Applicable",

"sch89attachment": "Not Applicable",

"t2054attachment": "Not Applicable",

"at1": "Not Applicable",

"co17": "Not Applicable",

"t1135": "Not Applicable",

"t1134": "Not Applicable",

"t106": "Not Applicable",

"rc4649": "Not Applicable",

"authorization": "Not Applicable",

"cancellation": "Not Applicable"

},

"eSignatureStatuses": {

"t183": "0",

"co1000": "0"

},

"preparer": null,

"reviewer": {

"userId": 1,

"firstName": "Marc",

"lastName": "Lacasse"

},

"partner": null,

"contactGroup": null,

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"

}],

"documentId": "9d8c3443-fbe5-43d1-bb3f-d3e5eba79671",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "WebAPI Created",

"labelId": "46918af7-78dc-49bc-9a9d-c82218c18ba6",

"lastModificationTimestamp": "2024-04-22T17:38:24Z",

“lastModificationActionType”: "deleted_comment"

}],

"prevCursor": null,

"nextCursor": null,

"errors": []

}

Example of getting a list of returns where the date modified starts from a specific date until this precise moment:

Request URL

https://mysite.cchifirm.ca/taxcan/api/partner/1.0/t2/documents/getList?returnManagerYear=2023

Request body

{

"perPage": 500,

"sortColumn": "date_modified",

"sortOrder": "Desc",

"filters": {

"date_modified": [

"2024-04-22T05:10:45Z"

]

}

}

Response body

{

"result": [

{

"taxationStartDate": "2023-01-01",

"taxationEndDate": "2023-12-31",

"taxpayers": [

{

"name": "Kreiger, Stoltenberg and Torphy",

"businessNumber": "#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "JS-177176138",

"efileStatuses": {

"t2": "Not Eligible",

"mr69": "Not Applicable",

"t2054": "Not Applicable",

"sch89": "Not Eligible",

"t2attachment": "Not Applicable ",

"t106attachment": "Not Applicable",

"t1134attachment": "Not Applicable",

"t1135attachment": "Not Applicable",

"sch89attachment": "Not Applicable",

"t2054attachment": "Not Applicable",

"at1": "Not Applicable",

"co17": "Not Applicable",

"t1135": "Not Applicable",

"t1134": "Not Applicable",

"t106": "Not Applicable",

"rc4649": "Not Applicable",

"authorization": "Not Applicable",

"cancellation": "Not Applicable"

},

"eSignatureStatuses": {

"t183": "0",

"co1000": "0"

},

"preparer": null,

"reviewer": {

"userId": 1,

"firstName": "Marc",

"lastName": "Lacasse"

},

"partner": null,

"contactGroup": null,

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"

}],

"documentId": "9d8c3443-fbe5-43d1-bb3f-d3e5eba79671",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "WebAPI Created",

"labelId": "10ae1db5-1736-44c0-b8ea-7f18aea380a1",

"lastModificationTimestamp": "2024-04-22T17:38:24Z",

“lastModificationActionType”: "changed_data_entered"

}],

"prevCursor": null,

"nextCursor": null,

"errors": []

}

Example of getting a list of returns where the T2 EFILE status is Eligible:

Request URL

https://mysite.cchifirm.ca/taxcan/api/partner/1.0/t2/documents/getList?returnManagerYear=2023

Request body

{

"perPage": 50,

"sortColumn": "date_modified",

"sortOrder": "Desc",

"filters": {

"t2_efile_status": [

"Eligible"

]

}

}

Response body

{

"result": [

{

"taxationStartDate": "2023-01-01",

"taxationEndDate": "2023-12-31",

"taxpayers": [

{

"name": "Jacobson, Dicki and Bashirian",

"businessNumber": "#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "768758758757649",

"efileStatuses": {

"t2": "Eligible",

"mr69": "Eligible",

"t2054": "Eligible",

"sch89": "Eligible",

"t2attachment": "Eligible ",

"t106attachment": "Eligible",

"t1134attachment": "Eligible",

"t1135attachment": "Eligible",

"sch89attachment": "Eligible",

"t2054attachment": "Eligible",

"at1": "Not Applicable",

"co17": "Eligible",

"t1135": "Eligible",

"t1134": "Eligible",

"t106": "Eligible",

"rc4649": "Not Applicable",

"authorization": "Not Applicable",

"cancellation": "Not Applicable"

},

"eSignatureStatuses": {

"t183": "0",

"co1000": "0"

},

"preparer": null,

"reviewer": null,

"partner": null,

"contactGroup": null,

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"

}],

"documentId": "27ec43d8-3dbf-478d-9715-7fa509548e90",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "",

"labelId": "10ae1db5-1736-44c0-b8ea-7f18aea380a1",

"lastModificationTimestamp": "2024-04-06T17:01:46Z",

“lastModificationActionType”: "published_form"

}],

"prevCursor": null,

"nextCursor": null,

"errors": []

}

Example of getting a list of returns that is filtered based on a Custom Filter:

Request URL

https://mysite.cchifirm.ca/taxcan/api/partner/1.0/t2/documents/getList?returnManagerYear=2023

Request body

{

"perPage": 50,

"sortColumn": "date_modified",

"sortOrder": "Desc",

"customReturnManagerFilterIds": [

337

]

}

Response body

{

"result": [

{

"taxationStartDate": "2023-01-01",

"taxationEndDate": "2023-12-31",

"taxpayers": [

{

"name": "Jacobson, Dicki and Bashirian",

"businessNumber": "#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "768758758757649",

"efileStatuses": {

"t2": "Eligible",

"mr69": "Eligible",

"t2054": "Eligible",

"sch89": "Eligible",

"t2attachment": "Eligible ",

"t106attachment": "Eligible",

"t1134attachment": "Eligible",

"t1135attachment": "Eligible",

"sch89attachment": "Eligible",

"t2054attachment": "Eligible",

"at1": "Not Applicable",

"co17": "Eligible",

"t1135": "Eligible",

"t1134": "Eligible",

"t106": "Eligible",

"rc4649": "Not Applicable",

"authorization": "Eligible",

"cancellation": "Eligible"

},

"eSignatureStatuses": {

"t183": 0,

"co1000": 0

},

"preparer": null,

"reviewer": null,

"partner": null,

"contactGroup": null,

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"",

"columnValues": {

"337": {

"FDFTC.Ttwftc5": "103000.54",

"FDFTC.Ttwftc537": "15075",

}

}

}],

"documentId": "27ec43d8-3dbf-478d-9715-7fa509548e90",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "",

"labelId": "10ae1db5-1736-44c0-b8ea-7f18aea380a1",

"lastModificationTimestamp": "2024-04-06T17:01:46Z",

“lastModificationActionType”: "imported_csv"

}],

"prevCursor": null,

"nextCursor": null,

"errors": []

}

/api/partner/1.0/t2/documents (POST)

Endpoint authentication

When adopting OAuth 2.0 as an authentication method, the below security requirements are needed in order to trigger this endpoint:

  • The user must fulfill the below security roles requirements; if he fails to obtain access to all the necessary security roles, an error 403: Insufficient privileges to execute this request is returned:

    • The user must acquire access to the following security roles:

      • Tax – Access T2 Product

      • Tax – Returns - Add

    • The user cannot create a document for a new contact if he does not have access to the below security role:

      • Contacts - View, Add and Edit Contacts

  • This endpoint validates against the user’s contact security. If the user does not have access to the contact associated to the document he is requesting to create, an error 404: Resource not found in the system is returned.

Endpoint description

Creates a new T2 document and once created, returns the metadata of the new document including its ID. This endpoint can manage to create a document from both an existing contact or for a new contact.

Creating a T2 document from an existing contact.

Model

{

"taxYearStartDate": "2023-01-01",

"taxYearEndDate": "2023-12-31",

"details": "string",

"labelId": "00000000-0000-0000-0000-000000000000",

"existingClientCode": "string"

}

Properties

taxYearStartDate: Taxation year-start date of the document.

taxYearEndDate: Taxation year-end date of the document.

details: Details to add to the document (optional).

labelId: The value of the label to be associated to the document (optional).

existingClientCode: Client Code of the existing contact for which you want to create a document.

Creating a T2 document from a new contact

Model

{

"taxYearStartDate": "2023-01-01",

"taxYearEndDate": "2023-12-31",

"newClient": {

"businessNumber": "#########RC####",

"name": "string",

"code": "string",

"group1Id": -1,

"group2Id": -1

},

"details": "string",

"labelId": "00000000-0000-0000-0000-000000000000"

}

Properties

taxYearStartDate: Taxation year-start date of the document.

taxYearEndDate: Taxation year-end date of the document.

businessNumber: Business number of the corporation.

name: Name of the corporation.

code: Client code of the new contact.

details: Details to add to the document (optional).

labelId: The value of the label to be associated to the document (optional).

group1Id: ID of the group1 option (optional: default to -1)

group2Id: ID of the group2 option (optional: default to -1)

Note: The “code” parameter is optional if the option Auto assign numeric client codes for new contacts has been enabled for your site.

Examples

 

Existing contact

New contact

Request URL

https://mysite.cchifirm.ca/taxcan/
api/partner/1.0/t2/documents

https://mysite.cchifirm.ca/taxcan/
api/partner/1.0/t2/documents

Request body

{

"taxYearStartDate": "2023-01-01",

"taxYearEndDate": "2023-12-31",

"details": "Copy-1",

"labelId": "415c4238-9117-d545-75k5-a6o5785bdba1",

"existingClientCode": "Abc123"

}

{

"taxYearStartDate": "2023-01-01",

"taxYearEndDate": "2023-12-31",

"newClient": {

"businessNumber": "#########RC####",

"name": "WebAPI Incorporated",

"code": "Abc1234"

"group1Id": -1,

"group2Id": -1

},

"details": "Copy-2",

"labelId": "415c4238-9117-d545-75k5-a6o5785bdba1"

}

Response body

{

"result": {

"taxationStartDate": "2023-01-01",

"taxationEndDate": "2023-12-31",

"taxpayers": [

{

"name": "WebAPI Incorporated",

"businessNumber": "#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "Abc123",

"efileStatuses": {

"t2": " Not Eligible",

"mr69": "Not Applicable",

"t2054": " Not Applicable",

"sch89": "Not Eligible",

"t2attachment": "Not Applicable",

"t106attachment": "Not Applicable",

"t1134attachment": "Not Applicable",

"t1135attachment": "Not Applicable",

"sch89attachment": "Not Applicable",

"t2054attachment": "Not Applicable",

"at1": "Not Applicable",

"co17": "Not Applicable",

"t1135": "Not Applicable",

"t1134": "Not Applicable",

"t106": "Not Applicable ",

"rc4649": "Not Applicable",

"authorization": "Not Applicable",

"cancellation": "Not Applicable"

},

"eSignatureStatuses": {

"t183": "0",

"co1000": "0"

},

"preparer": null,

"reviewer": null,

"partner": null,

"contactGroup": {

"id": 37,

"name": "Small businesses"

},

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"

}

],

"documentId": "9747c3f6-446f-4f7d-a24e-eb2eea7b3a67",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "Copy-1",

"labelId": "415c4238-9117-d545-75k5-a6o5785bdba1",

"lastModificationTimestamp": "2024-03-23T12:40:52Z",

“lastModificationActionType”: "changed_preparer_profile"

},

"errors": []

}

{

"result": {

"taxationStartDate": "2023-01-01",

"taxationEndDate": "2023-12-31",

"taxpayers": [

{

"name": "WebAPI Incorporated",

"businessNumber": "#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "Abc1234",

"efileStatuses": {

"t2": "Not Eligible",

"mr69": "Not Applicable",

"t2054": "Not Applicable",

"sch89": "Not Eligible",

"t2attachment": "Not Applicable",

"t106attachment": "Not Applicable",

"t1134attachment": "Not Applicable",

"t1135attachment": "Not Applicable",

"sch89attachment": "Not Applicable",

"t2054attachment": "Not Applicable",

"at1": "Not Applicable",

"co17": "Not Applicable",

"t1135": "Not Applicable",

"t1134": "Not Applicable",

"t106": "Not Applicable",

"rc4649": "Not Applicable",

"authorization": "Not Applicable",

"cancellation": "Not Applicable"

},

"eSignatureStatuses": {

"t183": "0",

"co1000": "0"

},

"preparer": null,

"reviewer": null,

"partner": null,

"contactGroup": {

"id": 37,

"name": "Small businesses"

},

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"

}

],

"documentId": "a4fd922a-e119-42f8-b9d1-405fc6547dab",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "Copy-2",

"labelId": "415c4238-9117-d545-75k5-a6o5785bdba1",

"lastModificationTimestamp": "2024-03-23T12:46:25Z",

“lastModificationActionType”: "changed_preparer_profile"

},

"errors": []

}

/api/partner/1.0/t2/documents/recycleBin (GET)

Endpoint authentication

When adopting OAuth 2.0 as an authentication method, the below security requirements are needed in order to trigger this endpoint:

  • The user must fulfill the below security roles requirements; if he fails to obtain access to all the necessary security roles, an error 403: Insufficient privileges to execute this request is returned:

    • The user must acquire access to the following security roles:

      • Tax – Access T2 Product

      • Tax – Recycle Bin – Access

  • • This endpoint validates against the user’s contact security and document visibility. If the user does not have access to a given document or to the contact associated to this document, the document will not be included in the response body.

Endpoint description

Returns a list of all T2 documents, with their associated metadata, that have been deleted and are in the recycle bin. This endpoint will also return all private documents that may not be visible to all users when accessing the recycle bin modal through the user interface.

Request URL

https://mysite.cchifirm.ca/taxcan/api/partner/1.0/t2/documents/recycleBin

Request body

N/A

Response body

{

"result": [{

"deletedBy": "UserName",

"deletedOn": "2024-04-07T14:50:26Z",

"taxationStartDate”: “2023-03-16”,

"taxationEndDate”: “2024-03-15”,

"taxpayers": [{

"name”: “Grant Inc",

"businessNumber": ""#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "10819",

"efileStatuses": {

"t2": " Eligible",

"mr69": "Not Applicable",

"t2054": " Not Eligible",

"sch89": "Not Eligible",

"t2attachment": "Eligible",

"t106attachment": "Not Applicable",

"t1134attachment": "Not Applicable",

"t1135attachment": "Not Applicable",

"sch89attachment": "Not Applicable",

"t2054attachment": "Not Applicable",

"at1": "Not Applicable",

"co17": "Eligible",

"t1135": "Not Applicable",

"t1134": "Not Applicable",

"t106": "Not Applicable ",

"rc4649": "Not Applicable",

"authorization": "Eligible",

"cancellation": "Eligible"

},

"eSignatureStatuses": {

"t183": "0",

"co1000": "0"

},

"preparer": {

"userId": 39,

"firstname": "Marc",

"lastname": "Lacasse"

},

"reviewer": {

"userId": 54,

"firstname": "Alex",

"lastname": "Tremblay"

},

"partner": null,

"contactGroup": null,

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"

}],

"documentId": "4e3f9358-9e0c-4488-a617-bd62f44b1a65",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "Details",

"labelId": "415c4238-9117-d545-75k5-a6o5785bdba1",

"lastModificationTimestamp": "2024-04-07T14:50:26Z",

“lastModificationActionType”: "moved_return_to_recycle_bin"

}],

"errors": []

}

/api/partner/1.0/t2/documents/{documentId} (GET)

Endpoint authentication

When adopting OAuth 2.0 as an authentication method, the below security requirements are needed in order to trigger this endpoint:

  • The user must fulfill the below security roles requirements; if he fails to obtain access to all the necessary security roles, an error 403: Insufficient privileges to execute this request is returned:

    • The user must acquire access to the following security role:

      • Tax – Access T2 Product

  • This endpoint validates against the user’s contact security and document visibility. If the user does not have access to the document provided in the URL or the contact associated to this document, an error 404: Resource not found in the system is returned.

Endpoint description

Returns a specific T2 document with all metadata available in the return manager.

The GUID of the document must be inserted in the URL of the request.

Model

N/A

Properties

N/A

Examples

Request URL

https://mysite.cchifirm.ca/taxcan/api/partner/1.0/t2/documents/9747c3f6-446f-4f7d-a24e-eb2eea7b3a67

Request body

N/A

Response body

{

"result": {

"taxationStartDate": "2023-01-01",

"taxationEndDate": "2023-12-31",

"taxpayers": [

{

"name": "WebAPI Incorporated",

"businessNumber": "#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "Abc123",

"efileStatuses": {

"t2": " Not Eligible",

"mr69": "Not Applicable",

"t2054": " Not Applicable",

"sch89": "Not Eligible",

"t2attachment": "Not Applicable",

"t106attachment": "Not Applicable",

"t1134attachment": "Not Applicable",

"t1135attachment": "Not Applicable",

"sch89attachment": "Not Applicable",

"t2054attachment": "Not Applicable",

"at1": "Not Applicable",

"co17": "Not Applicable",

"t1135": "Not Applicable",

"t1134": "Not Applicable",

"t106": "Not Applicable ",

"rc4649": "Not Applicable",

"authorization": "Not Applicable",

"cancellation": "Not Applicable"

},

"eSignatureStatuses": {

"t183": "0",

"co1000": "0"

},

"preparer": null,

"reviewer": null,

"partner": null,

"contactGroup": null,

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"

}

],

"documentId": "9747c3f6-446f-4f7d-a24e-eb2eea7b3a67",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "Copy-3",

"labelId": "415c4238-9117-d545-75k5-a6o5785bdba1",

"lastModificationTimestamp": "2024-02-23T12:40:52Z",

“lastModificationActionType”: "imported_gifi"

},

"errors": []

}

Note: The “group1Id” and “group2Id” properties are always returned in the document endpoint responses even if groups are not activated for your site. The ID -1 represents the “None” group option.

/api/partner/1.0/t2/documents/{documentId}/copy (POST)

Endpoint authentication

When adopting OAuth 2.0 as an authentication method, the below security requirements are needed in order to trigger this endpoint:

  • The user must fulfill the below security roles requirements; if he fails to obtain access to all the necessary security roles, an error 403: Insufficient privileges to execute this request is returned:

    • The user must acquire access to the following security roles:

      • Tax – Access T2 Product

      • Tax – Returns – Copy

  • This endpoint validates against the user’s contact security and document visibility. If the user does not have access to the document provided in the URL or the contact associated to this document, an error 404: Resource not found in the system is returned.

Endpoint description

Copies a specific document in the T2 product. The GUID of the document must be inserted in the URL of the request.

Model

{

"details": "string",

"labelId": "00000000-0000-0000-0000-000000000000"

}

Properties

details: Optional parameter to add details to the copied document.

labelId: Optional parameter to add a label to the copied document.

Examples

Request URL

https://mysite.cchifirm.ca/taxcan/api/partner/1.0/t2/documents/fedf6b5d-3d01-4276-899e-19fe2d222388/copy

Request body

{

"details": "Scenario 1",

"labelId": "415c4238-9117-d545-75k5-a6o5785bdba1"

}

Response body

{

"result": {

"taxationStartDate": "2023-01-01",

"taxationEndDate": "2023-12-31",

"taxpayers": [

{

"name": "WebAPI Incorporated",

"businessNumber": "#########RC####",

"noaStatus": "Not Downloaded",

"returnId": 0,

"clientCode": "Abc123",

"efileStatuses": {

"t2": " Eligible",

"mr69": "Not Applicable",

"t2054": " Not Applicable",

"sch89": "Not Eligible",

"t2attachment": "Eligible",

"t106attachment": "Eligible",

"t1134attachment": "Not Applicable",

"t1135attachment": "Not Applicable",

"sch89attachment": "Not Applicable",

"t2054attachment": "Not Applicable",

"at1": "Not Applicable",

"co17": "Not Applicable",

"t1135": "Not Applicable",

"t1134": " Eligible”,

"t106": "Eligible",

"rc4649": "Not Applicable",

"authorization": "Not Applicable",

"cancellation": "Not Applicable"

},

"eSignatureStatuses": {

"t183": "0",

"co1000": "0"

},

"preparer": null,

"reviewer": null,

"partner": null,

"contactGroup": null,

"returnStatusId": "415c4238-9117-d545-85b5-a6c5717bdba1",

"group1Id": -1,

"group2Id": -1,

"environmentId": "d6d50e87-7189-4ac9-b136-cc849412f4c3"

}],

"documentId": "9747c3f6-446f-4f7d-a24e-eb2eea7b3a67",

"isLocked": false,

"isPrivate": false,

"wasRolledForward": false,

"details": "Scenario 1",

"labelId": "415c4238-9117-d545-75k5-a6o5785bdba1",

"lastModificationTimestamp": "2024-02-23T12:40:52Z",

“lastModificationActionType”: "retrieved_wac"

},

"errors": []

}

wasRolledForward parameter limitation

The parameter "wasRolledForward" is returned for every year and period. However, the parameter will display the “false” default value for all T2 documents prior to 2018.

/api/partner/1.0/t2/documents/delete (POST)

Endpoint authentication

When adopting OAuth 2.0 as an authentication method, the below security requirements are needed in order to trigger this endpoint:

  • The user must fulfill the below security roles requirements; if he fails to obtain access to all the necessary security roles, an error 403: Insufficient privileges to execute this request is returned:

    • The user must acquire access to the following security roles:

      • Tax – Access T2 Product

      • Tax – Returns – Delete

This endpoint validates against the user’s contact security and document visibility. If the user does not have access to the documents provided in the request body or the contact associated to these documents, an error 404: Resource not found in the system is returned.

Endpoint description

Deletes one document or a batch of documents and moves them to the Recycle Bin. The GUID of the document(s) must be provided in the request body.

Model

{

"documentIds": [

"string"

]

}

Properties

documentIds: The GUID(s) array of documents can be retrieved by creating a get request using the Documents endpoint.

Examples

Request URL

https://mysite.cchifirm.ca/taxcan/api/partner/1.0/t2/documents/delete

Request body

{

"documentIds": [

" fedf6b5d-3d01-4276-899e-19fe2d222388"

]

}

Response body

{

"errors": []

}