Quote TS Update JSON API

Have more questions? Submit a request

A JSON API performs the OASIS function of updating an OASIS project. The following areas will be covered:

  • Connectivity
  • Request Content
  • Response Content

Requirements

  • Users must have O4. To learn more about moving forward with O4, contact OASIS Sales at sales@oasissalessoftware.com or 501-843-6750.
  • Users must create bearer tokens in O4 to authorize the call in their external API software.

 

Connectivity

An OASIS web service that receives web client requests via JSON.

Call

Software-based call

URL: <O4 Database URL>/API?&ajax=QuoteTSUpdate

JSON POST method
Example:
      java.net.http.HttpRequest request = java.net.http.HttpRequest.newBuilder()
        .uri(java.net.URI.create("http://localhost:8080/OASIS/API?ajax=QuoteTSUpdate"))
        .header("Content-Type", "application/json")
        .header("User-Agent", "OASIS")
        .header("Authorization", "Bearer the token value")
        .method("POST", java.net.http.HttpRequest.BodyPublishers.ofString(JSON request content))
        .build();
      java.net.http.HttpResponse<String> response = java.net.http.HttpClient.newHttpClient().send(request, java.net.http.HttpResponse.BodyHandlers.ofString());

 

Request Content

The OASIS web service handles the update of one OASIS project at a time. 

QuoteTS

The request content must start with {“QuoteTS”:{…}}

Required:

  • DBID – “DBID”:”OASIS database ID”
  • QuoteID – “QuoteID”:”OASIS Quote ID”

Additional parameters of “QuoteTS”:

  • QuoteHeader
  • PhaseHeader
  • Specifiers
  • Customers
  • Alias
  • UserTags
  • Followups
  • QuoteLines

QuoteHeader

QuoteHeader provides information used in updating the overview and providing quotes for the OASIS project.

Format

QuoteHeader”:{“Project”:”value”,”Location”:”value”,”LocationState”:”value”,…}

Supported Fields

  • Project
  • BidName
  • Location
  • LocationState
  • BSID
  • SpecRegistration
  • NationalAccount
  • VerticalMarket
  • BidBoard
  • Status
  • InternalNotes
  • Remarks
  • QuoteNotes
  • PORemarks
  • PONotes
  • ShippingInstructions
  • DoNotShipBefore
  • RequiredOnSite
  • LotPriceOrder
  • Stamp
  • FreightType
  • TaxExemptionNumber
  • BidDate
  • RADate
  • ExpirationDate
  • ShipName
  • ShipCO
  • ShipLine1
  • ShipLine2
  • ShipCity
  • ShipState
  • ShipZip
  • ShipCounty
  • ShipCountry
  • ShipMark
  • ShipCallAhead
  • AltName
  • AltCO
  • AltLine1
  • AltLine2
  • AltCity
  • AltState
  • AltZip
  • AltCounty
  • AltCountry
  • AltWhenToUse
  • ContractorPO
  • FreightAccount
  • BillName
  • BillLine1
  • BillLine2
  • BillCity
  • BillState
  • BillZip
  • BillCounty
  • BillCountry
  • CSRUserID
  • QuoterUserID
  • CreateTerritoryID

 

PhaseHeader

PhaseHeader provides information used in the update of the phase of the OASIS project.

Format

PhaseHeader”:{“PhaseName”:”value”,”Active”:”value”,”Valuation”:”value”,…}

Supported Fields

  • PackageName/PhaseName
  • Owner
  • Active
  • StartDate
  • CompletionDate
  • Valuation
  • SquareFootage
  • ValuationLighting
  • ValuationControls
  • SpecifiedProject
  • ImportantProject
  • PSpecified
  • PApproved
  • GCAwarded
  • GCFullText
  • GCDistributorID
  • GCContactDBID
  • GCContactID
  • ECAwarded
  • ECFullText
  • ECDistributorID
  • ECContactDBID
  • ECContactID
  • LowDistributorAwarded
  • LowDistributorID
  • LowDistContactDBID
  • LowDistContactID
  • ExternalProjectNumber
  • ProjectRank
  • Notes

 

Specifiers

Specifiers provides information to create, update, or delete specifiers within the OASIS quote.

Format

“Specifiers”:[{“action”:”add”,”CustomerID”:”value”,”Role”:”value”},”Influence”:”value”},”SalesUserID”:”value”}]

JSON Keys

Required:

  • Action – “add,” "update," "delete"
    • If action is not present, the action taken by default is "update"
  • CustomerID – value must match the internal ID of an OASIS customer entry

Optional:

These values are used to override the default values defined for an OASIS customer entry.

  • Role – value match to customer roles defined in OASIS
  • Influence – Integer value required
  • SalesUserID – value match to sales account entry defined in OASIS

 

Customers

Customers provides information to create, update, or delete customers within the OASIS quote.

Format

“Customers”:[{“action”:”value”,”CustomerID”:”value”,” IncludeLamps”:”value”,…}]

A JSON array format is required for the Customers JSON key.

Supported Fields

Required:

  • Action – “add,” "update," "delete"
    • If action is not present, the action taken by default is "update"
  • CustomerID – value must match the internal ID of an OASIS customer entry

Optional:

These values are used to override the default values defined for an OASIS customer entry.

  • IncludeLamps– Boolean value– true}false or “Y”|”N”
  • WinLoss – Integer value
    • -1 to signify loss
    • 0 to signify no choice
    • 1 to signify win
  • LotPrice – numerical value
  • Column – set price level 0, 1, 2, or 3
  • Markup – numerical value

 

Alias

Alias provides information to add or delete an alias entry from an OASIS project.

Format

“Alias”:[{“action”:”value”,”Alias”:”value”}]

A JSON array format is required for the Alias JSON key.

Supported Fields

Required:

  • Action – “add,” "update," "delete"
  • Alias – value of project name alias

 

UserTags

UserTags provides information to create, update, or delete user tags within the OASIS quote.

Format

“UserTags”:[{“action”:”value”,”TagKey”:”value”,”TagValue”:”value”}]

A JSON array format is required for the UserTags JSON key.

Supported Fields

Required:

  • Action – valid values are “add”, "update", "delete"
  • TagKey – value of the tag key
  • TagValue – value to assign to the user tag

 

FollowUps

FollowUps provides information to create followup entries within the OASIS quote.

Format

“FollowUps”:[{“action”:”add”,”Notes”:”value”,…}]

A JSON array format is required for the FollowUps JSON key.

Supported Fields

Required:

  • Action – valid values are “add”

Optional:

  • Notes –the note content of the followup.
  • UserID – ID of the user creating the followup. The user account must be present in OASIS.
  • DistributorID – ID of the customer/specifier of the followup.
  • ContactDBID – Database ID of the contact for the followup. The contact account must be present in OASIS.
  • ContactID – ID of the contact for the followup. The contact account must be present in OASIS.

 

QuoteLines

QuoteLines provides information to create, update, or delete bill of material lines within the OASIS quote.

Format

QuoteLines”:[{“action”:”value”,”ManufacturerID”:”value”,”Catalog”:”value”,…}]

A JSON array format is required for the QuoteLines JSON key.

Supported Fields

Required:

  • Action – valid values are “add,” "update," "delete"
    • "update" and "delete" requires the "LineUID" JSON key to identify the OASIS quote line

Optional:

  • LineUID (required for update and delete actions)
  • Code
  • Quantity
  • Type
  • ManufacturerID
  • Catalog
  • Description
  • Note
  • INote
  • Cost
  • Sell
  • SellCommission
  • Level1
  • Level1Commission
  • Level2
  • Level2Commission
  • Level3
  • Level3Commission
  • OBase
  • OBaseCommission
  • Base
  • BaseCommission

Response Content

A successful response code is 200.

The response will contain a JSON structure of the data that was successfully applied.

Example:

Request
{
   "QuoteID":"186001635",
   "DBID":"MY O4 OASIS DBID",””
   "QuoteTS":{
      "PhaseHeader":{
         "Owner":"The new owner"
      },
      "Specifiers":[
         {
            "Role":"Architect",
            "action":"add",
            "CustomerID":"CustID1"
         }
      ]
   }
}


Response
{
   "QuoteTS":[
      {
         "Phase":{
            "Owner":"The new owner",
            "DBID":"MY O4 OASIS DBID",
            "ProjectID":"186003060",
            "PackageID":"186003062"
         },
         "Specifiers":[
            {
               "Role":"Architect",
               "CompanyName":"iNeedLights",
               "CustomerID":"CustID1"
            }
         ]
      }
   ]
}

 

Articles in this section

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.