Hey All! I'm trying to send timebills using SuiteT...
# integrations
s
Hey All! I'm trying to send timebills using SuiteTalk SOAP APIs using a NodeJS service. No matter whatever i try i get _"Error performing UpsertList: Error: faultcode: soapenv:Server.userException faultstring: org.xml.sax.SAXException: {urn:core_2023_2.platform.webservices.netsuite.com}Record is an abstract type and cannot be instantiated detail: {"hostname":"partnersXXX.prod-kxx-xx0.core.ns.internal"}"_ Payload Looks something like this:
Copy code
const requestBody = {
        "platformMsgs:upsertList": {
          $attributes: {
            'xsi:type': 'platformMsgs:UpsertListRequest'
          },
          record: [
            {
              $attributes: {
                'xsi:type': 'tranEmp:TimeBill',
                externalId: data.externalId,
                recordType: 'timeBill' // Include recordType here
              },
              employee: {
                $attributes: {
                  internalId: data.employee.internalId,
                  'xsi:type': 'platformCore:RecordRef'
                }
              },
              tranDate: data.tranDate,
              approvalStatus: {
                $attributes: {
                  internalId: data.approvalStatus.internalId,
                  'xsi:type': 'platformCore:RecordRef'
                }
              },
              customer: {
                $attributes: {
                  internalId: data.customer.internalId,
                  'xsi:type': 'platformCore:RecordRef'
                }
              },
              caseTaskEvent: {
                $attributes: {
                  internalId: data.caseTaskEvent.internalId,
                  'xsi:type': 'platformCore:RecordRef'
                }
              },
              hours: {
                $attributes: {
                  'xsi:type': 'platformCore:Duration'
                },
                timeSpan: data.hours.timeSpan,
                unit: data.hours.unit
              },
              isBillable: data.isBillable,
              department: {
                $attributes: {
                  internalId: data.department.internalId,
                  'xsi:type': 'platformCore:RecordRef'
                }
              },
              rate: data.rate
            }
          ]
        } };
Any ideas? Am i missing something here?