Accounting API Developer's Reference

c2g.CODAAPISalesInvoice_10_0

global with sharing class CODAAPISalesInvoice_10_0

The service class relating to Sales Invoices.

Properties

Name Type Description
VERSION_STRING String The API version.
SERVICE_NAME String The name of the service.

Methods

GetAPIVersion

webservice static String GetAPIVersion()

Used to get the latest API version.

Return Value

Text

GetServiceName

webservice static String GetServiceName()

Used to get the name of the service.

Return Value

Text

CreateInvoice

webservice static c2g.CODAAPICommon.Reference CreateInvoice(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPIInvoiceTypes_10_0.Invoice value)

This service allows you to create a sales invoice. See "Sales Invoice Fields" and "What is a Sales Invoice" in the FinancialForce Help for more details.

This version of the service allows you to create a sales invoice in a company that is not selected as the current company:

  • When creating a sales invoice using the FinancialForce API, you must specify the company name using the context.CompanyName input parameter.
  • When creating a sales invoice using the Salesforce API you must specify the company name using the invoice.OwnerCompany field.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
value c2g.CODAAPIInvoiceTypes_10_0.Invoice Holds details of the sales invoice you want to create.

Return Value

This web service returns a CODAAPICommon.Reference object.

CreateRecurringInvoice

webservice static void CreateRecurringInvoice(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPIInvoiceTypes_10_0.Invoice value)

This service allows you to create a recurring sales invoice.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
value c2g.CODAAPIInvoiceTypes_10_0.Invoice Holds details of the recurring sales invoice you want to create.

Return Value

This web service does not return a value.

UpdateInvoice

webservice static c2g.CODAAPICommon.Reference UpdateInvoice(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPIInvoiceTypes_10_0.Invoice value)

This service allows you to update a sales invoice.

This version of the service allows you to update a sales invoice in a company that is not selected as the current company:

  • When updating a sales invoice using the FinancialForce API, you must specify the company name using the context.CompanyName input parameter.
  • When updating a sales invoice using the Salesforce API you must specify the company name using the invoice.OwnerCompany field.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
value c2g.CODAAPIInvoiceTypes_10_0.Invoice Holds details of the sales invoice you want to update.

Return Value

This web service returns a CODAAPICommon.Reference object.

PostInvoice

webservice static void PostInvoice(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPICommon.Reference value)

This service allows you to post a sales invoice.
If FinancialForce Accounting is integrated with Avalara's AvaTax product for the calculation of Sales and Use Tax, see "Posting Sales Documents That Have Their Tax Value Calculated by AvaTax" for advice about which service to use for posting your sales documents.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
value c2g.CODAAPICommon.Reference Identifies the sales invoice you want to post.

Return Value

This web service does not return a value.

PostIncomeSchedules

Not for public use.

webservice static void PostIncomeSchedules(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPICommon.Reference value)

GetInvoice

webservice static c2g.CODAAPIInvoiceTypes_10_0.Invoice GetInvoice(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPICommon.Reference value)

This service allows you to retrieve a sales invoice.

This version of the service allows you to retrieve a sales invoice from a company that is not selected as the current company:

  • When retrieving a sales invoice using the FinancialForce API, you must specify the company name using the context.CompanyName input parameter.
  • When retrieving a sales invoice using the Salesforce API you must specify the company name using the invoice.OwnerCompany field.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
value c2g.CODAAPICommon.Reference Identifies the sales invoice you want to retrieve.

Return Value

This web service returns a c2g.CODAAPIInvoiceTypes_10_0.Invoice object.

PrintInvoiceToEmail

webservice static void PrintInvoiceToEmail(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPICommon.Reference value)

This service allows you to print a sales invoice by emailing it to the account.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
value c2g.CODAAPICommon.Reference Identifies the sales invoice you want to print.

Return Value

This web service does not return a value.

PrintInvoice

webservice static Blob PrintInvoice(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPICommon.Reference value)

This service allows you to print a sales invoice to a PDF file.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
value c2g.CODAAPICommon.Reference Identifies the sales invoice you want to print.

Return Value

This web service returns a Blob object.

MarkAsPrinted

webservice static void MarkAsPrinted(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPICommon.Reference value)

This service allows you to set the Printed flag on a sales invoice to record that it has been printed.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
value c2g.CODAAPICommon.Reference Identifies the sales invoice you want to mark as printed.

Return Value

This web service does not return a value.

BulkCreateInvoice

webservice static c2g.CODAAPICommon.Reference[] BulkCreateInvoice(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPIInvoiceTypes_10_0.Invoice[] values)

This service allows you to create sales invoices in bulk.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
values c2g.CODAAPIInvoiceTypes_10_0.Invoice[] Holds details of the sales invoices you want to create.

Return Value

This web service returns an array of CODAAPICommon.Reference objects.

BulkUpdateInvoice

webservice static c2g.CODAAPICommon.Reference[] BulkUpdateInvoice(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPIInvoiceTypes_10_0.Invoice[] values)

This service allows you to update sales invoices in bulk.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
values c2g.CODAAPIInvoiceTypes_10_0.Invoice[] Holds details of the sales invoices you want to update.

Return Value

This web service returns an array of CODAAPICommon.Reference objects.

BulkPostInvoice

webservice static void BulkPostInvoice(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPICommon.Reference[] values)

This service allows you to post sales invoices in bulk.
If FinancialForce Accounting is integrated with Avalara's AvaTax product for the calculation of Sales and Use Tax, see "Posting Sales Documents That Have Their Tax Value Calculated by AvaTax" for advice about which service to use for posting your sales documents.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
values c2g.CODAAPICommon.Reference[] Identifies the sales invoices you want to post.

Return Value

This web service does not return a value.

BulkMarkAsPrinted

webservice static void BulkMarkAsPrinted(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPICommon.Reference[] values)

This service allows you to set the Printed flag on sales invoices to record that they have been printed.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
values c2g.CODAAPICommon.Reference[] Identifies the sales invoices you want to mark as printed.

Return Value

This web service does not return a value.

BulkAmendInvoice

webservice static void BulkAmendInvoice(c2g.CODAAPICommon_10_0.Context context, List<c2g.CODAAPIInvoiceTypes_10_0.InvoiceForAmend> headers)

This service allows you to amend posted sales invoices in bulk.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
headers List<c2g.CODAAPIInvoiceTypes_10_0.InvoiceForAmend> Holds details of the sales invoices that you want to amend.

Return Value

This web service does not return a value.

BulkAmendInvoiceLineItem

webservice static void BulkAmendInvoiceLineItem(c2g.CODAAPICommon_10_0.Context context, List<c2g.CODAAPIInvoiceLineItemTypes_10_0.InvoiceLineItemForAmend> lines)

This service allows you to amend posted sales invoice lines in bulk.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
lines List<c2g.CODAAPIInvoiceLineItemTypes_10_0.InvoiceLineItemForAmend> Holds details of the sales invoice lines that you want to amend.

Return Value

This web service does not return a value.

ScheduleInvoicesForPosting

webservice static void ScheduleInvoicesForPosting(c2g.CODAAPICommon_10_0.Context context, c2g.CODAAPICommon.Reference[] values)

See "Posting Sales Documents That Have Their Tax Value Calculated by AvaTax" for information about using this service.

Input Parameters

Name Type Description
context c2g.CODAAPICommon_10_0.Context Identifies the FinancialForce company in which the current operation executes.
values c2g.CODAAPICommon.Reference[] Identifies the sales invoices you want to schedule for posting.

Return Value

This web service does not return a value.