openapi: 3.0.1
info:
  title: Social Value Portal APIs
  description: |
    Welcome to SVP APIs. IDs for records may be 15 or 18 digits long; the 15 digit version is case sensitive, the 18 digit version appends three optional characters to make it case insensitive. Dates should be formatted dd/mm/yyyy.
    - Updated descriptions for endpoints and parameters
    - Corrections on parameter names for account and account-hierarchies
    - Corrections and descriptions to schemas
    - Addition of details for SOAP authentication
    - Target details moved to 'Answers' in GET projects-related-lists
  version: 2.2.0
servers:
- url: https://socialvalueportal.my.salesforce.com
paths:
  /services/oauth2/token:
    post:
      tags:
      - Authentication
      summary: Obtain an Authorisation Token
      description: "Returns authorisation token used for resource requests, using JWT Bearer Flow."
      requestBody:
        content:
          application/x-www-form-urlencoded:
            schema:
              $ref: "#/components/schemas/oauth2_token_body"
        required: true
      responses:
        "200":
          description: Successful
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/inline_response_200"
              example:
                access_token: "1122334455"
                scope: api
                instance_url: https://socialvalueportal.my.salesforce.com
                id: https://socialvalueportal.salesforce.com/id/00XXXXXXXXXXXX/00XXXXXXXXXXXX
                token_type: Bearer
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/inline_response_400"
              examples:
                invalid_grant:
                  value: |-
                    {
                      "error" : "invalid_grant",
                      "error_description" : "expired authorization code"
                    }
                unsupported_grant_type:
                  value: |-
                    {
                      "error" : "unsupported_grant_type",
                      "error_description" : "grant type not supported"
                    }
  /services/Soap/u/56.0:
    post:
      tags:
      - Authentication
      summary: SOAP Authentication Service
      description: |
        This endpoint handles SOAP-based authentication requests for the Salesforce API. The SOAP request must include a properly formatted SOAP envelope with necessary headers and body content for login. An example of a request payload is provided below, but note that actual SOAP requests must be made with appropriate SOAP action headers and content types (text/xml). The organizationId for our Production instance is: 00D28000000L57N. Please ask if you require a sandbox to test your connection, and we will provide the organizationId.
        - **Request Example**: ```xml <env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
            <env:Header>
                <LoginScopeHeader xmlns="urn:partner.soap.sforce.com">
                    <organizationId>00D28000000L57N</organizationId>
                </LoginScopeHeader>
            </env:Header>
            <env:Body>
                <n1:login xmlns:n1="urn:partner.soap.sforce.com">
                    <n1:username>your.username@socialvalueportal.com</n1:username>
                    <n1:password>your.Password!</n1:password>
                </n1:login>
            </env:Body>
        </env:Envelope> ```
      operationId: soapLogin
      parameters:
      - name: Content-Type
        in: header
        description: Content type of the SOAP request.
        required: true
        schema:
          type: string
          default: text/xml
      - name: SOAPAction
        in: header
        description: SOAPAction header required by SOAP protocol. Leave as empty string if not needed.
        required: true
        schema:
          type: string
          default: ""
      requestBody:
        description: SOAP request envelope for authentication (see schema for details)
        content:
          text/xml:
            schema:
              type: string
              example: |-
                <env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
                    <env:Header>
                        <LoginScopeHeader xmlns="urn:partner.soap.sforce.com">
                            <organizationId>00D3K0000009pyK</organizationId>
                        </LoginScopeHeader>
                    </env:Header>
                    <env:Body>
                        <n1:login xmlns:n1="urn:partner.soap.sforce.com">
                            <n1:username>your.username@socialvalueportal.com</n1:username>
                            <n1:password>your.Password!</n1:password>
                        </n1:login>
                    </env:Body>
                </env:Envelope>
        required: true
      responses:
        "200":
          description: Successfully authenticated (see schema for details).
          content:
            application/xml:
              schema:
                type: string
                example: |-
                  <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns="urn:partner.soap.sforce.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
                      <soapenv:Body>
                          <loginResponse>
                              <result>
                                  <metadataServerUrl>https://socialvalueportal.my.salesforce.com/services/Soap/m/56.0/00D3L0000009pyK</metadataServerUrl>
                                  <passwordExpired>false</passwordExpired>
                                  <serverUrl>https://socialvalueportal.my.salesforce.com/services/Soap/u/56.0/00D3L0000009pyK</serverUrl>
                                  <sessionId>00D3L0000009pyK!AQEKQER8QpwCx77qefRsEkdDQIabd5Z5XZwpviqN.JBT_6aI.FaW7FQIQUe4AjMqZDZiVGeFtecbj2JaVLAOFWQ8tpL_IrC8</sessionId>
                                  <userId>005Gd0000027KOaIAM</userId>
                                  <userInfo>
                                      ...
                                  </userInfo>
                              </result>
                          </loginResponse>
                      </soapenv:Body>
                  </soapenv:Envelope>
        "500":
          description: Internal Server Error or malformed request (see schema for details).
          content:
            application/xml:
              schema:
                type: string
                example: |-
                  <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sf="urn:fault.partner.soap.sforce.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
                      <soapenv:Body>
                          <soapenv:Fault>
                              <faultcode>sf:INVALID_LOGIN</faultcode>
                              <faultstring>INVALID_LOGIN: Invalid username, password, security token; or user locked out.</faultstring>
                              <detail>
                                  <sf:LoginFault xsi:type="sf:LoginFault">
                                      <sf:exceptionCode>INVALID_LOGIN</sf:exceptionCode>
                                      <sf:exceptionMessage>Invalid username, password, security token; or user locked out.</sf:exceptionMessage>
                                  </sf:LoginFault>
                              </detail>
                          </soapenv:Fault>
                      </soapenv:Body>
                  </soapenv:Envelope>
  /services/apexrest/v2/accounts:
    get:
      tags:
      - Accounts
      description: Returns details for one or more specified accounts
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`\n"
        required: true
        schema:
          type: string
      - name: id
        in: query
        description: "A comma-separated list of 15 or 18 digit Salesforce IDs for the account, each starting with 001. Example: '001ABC123456789,001XYZ987654321'."
        required: true
        schema:
          pattern: "^001[\\da-zA-Z]{12,15}(,001[\\da-zA-Z]{12,15})*$"
          type: string
      responses:
        "200":
          description: API Answer
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/v2_Accounts"
              examples:
                example1:
                  value: |-
                    [
                      {
                          "ultimateParent": "Acme Global Ltd",
                          "postCode": "SE1 7TY",
                          "parentId": "0018E00001zH7NKQA0",
                          "membershipStart": "2023-02-21",
                          "membershipEnd": "2024-03-26",
                          "location": {
                              "latitude": 51.487955,
                              "longitude": -0.123739
                          },
                          "id": "0018E00001zIGULQA4",
                          "accountQuestionnaire": "National TOMs",
                          "accountName": "Acme Ltd"
                      }
                    ]
  /services/apexrest/v2/account-hierarchies:
    get:
      tags:
      - Accounts
      description: Returns all the sub-accounts and the parent-child relationship structure for the specified account. Relationship is defined by the ParentID on each account record.
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`\n"
        required: true
        schema:
          type: string
      - name: id
        in: query
        description: "A comma-separated list of 15 or 18 digit Salesforce IDs for the account, each starting with 001. Example: '001ABC123456789,001XYZ987654321'."
        required: true
        schema:
          pattern: "^001[\\da-zA-Z]{12,15}(,001[\\da-zA-Z]{12,15})*$"
          type: string
      responses:
        "200":
          description: API Answer
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/v2_Account-hierarchies"
              examples:
                example1:
                  value: |-
                    [ {
                      "ParentName" : "API Test Account",
                      "ParentID" : "0012600001Af96yAAB",
                      "Name" : "Test API Child One",
                      "ID" : "0012600001AgGGXAA3"
                    }, {
                      "ParentName" : "Test API Child One",
                      "ParentID" : "0012600001AgGGXAA3",
                      "Name" : "Test API Child Two",
                      "ID" : "0012600001AgGNOAA3"
                    }, {
                      "ParentName" : "Test API Child Two",
                      "ParentID" : "0012600001AgGNOAA3",
                      "Name" : "Test API Child Three",
                      "ID" : "0012600001AgGNdAAN"
                    } ]
      servers:
      - url: https://socialvalueportal.my.salesforce.com
  /services/apexrest/v2/toms:
    get:
      tags:
      - Account related information
      description: Returns a list of TOM sets (sets of social value measures/questionnaires) associated to the specified account. The TOM set ID is required for new project creation.
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`\n"
        required: true
        schema:
          type: string
      - name: accountId
        in: query
        description: "A single or comma separated list of Account ID's (15 or 18 digit Salesforce ID, starting 001). Example: '001ABC123456789,001XYZ987654321'."
        required: true
        schema:
          pattern: "^a00[\\da-zA-Z]{12,15}(,a00[\\da-zA-Z]{12,15})*$"
          type: string
      responses:
        "200":
          description: API Answer
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/inline_response_200_1"
              examples:
                example1:
                  value: |-
                    [
                        {
                            "year": "2021",
                            "name": "International TOMs",
                            "id": "a008E00000N4uGgQAJ"
                        },
                        {
                            "year": "2022",
                            "name": "National TOMs",
                            "id": "a008E00000MxgKoQAJ"
                        },
                        {
                            "year": "2022",
                            "name": "Social Example TOM",
                            "id": "a008E00000MxgZtQAJ"
                        }
                    ]
  /services/apexrest/v2/industries:
    get:
      tags:
      - Account related information
      description: "Returns a list of Industries that may be used with a specified TOM set (questionnaire). Each project must be assigned an industry record to calculate economic proxies. Data is updated periodically, so an industry record with the correct reporting year, matching the TOM set reporting year, must be specified for project creation."
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`        \n"
        required: true
        schema:
          type: string
      - name: questionnaireId
        in: query
        description: "A single or comma-separated list of TOM set (Questionnaire) IDs (15 or 18 digit Salesforce ID, starting a00). Example: 'a00ABC123456789,a00XYZ987654321'."
        required: false
        schema:
          pattern: "^a00[\\da-zA-Z]{12,15}(,a00[\\da-zA-Z]{12,15})*$"
          required:
          - questionnaireId
          type: string
      responses:
        "200":
          description: API Answer
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/inline_response_200_2"
              examples:
                example1:
                  value: |-
                    [
                      {
                          "year": "2022",
                          "industryName": "Construction",
                          "id": "a0H8E00000EMANFUA5"
                      },
                      {
                          "year": "2022",
                          "industryName": "Creative, arts and entertainment services",
                          "id": "a0H8E00000EMANGUA5"
                      },
                      {
                          "year": "2022",
                          "industryName": "Education services",
                          "id": "a0H8E00000EMANHUA5"
                      }
                    ]
  /services/apexrest/v2/contacts:
    get:
      tags:
      - Account related information
      description: Returns a list of user details associated to the specified Account and all related child sub-accounts in the account hierarchy.
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`\n"
        required: true
        schema:
          type: string
      - name: accountId
        in: query
        description: "A single or comma separated list of Account IDs (15 or 18 digit Salesforce ID, starting 001)"
        required: false
        schema:
          required:
          - accountId
          type: string
      responses:
        "200":
          description: API Answer
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: "#/components/schemas/inline_response_200_3"
              examples:
                example1:
                  value: |-
                    [
                      {
                          "id": "0038E00001UAGuSQAX",
                          "email": "jane.doe@mail.com",
                          "name": "Jane Doe",
                          "accountName": "Doe Industries",
                          "accountId": "001Vg0000052d5tIAA"
                      },
                      {
                          "id": "0038E00001U9xfiQAB",
                          "email": "john.doe@mail.com",
                          "contactName": "John Doe",
                          "accountName": "Acme Ltd",
                          "accountId": "001Vg0000062d5rIAA"
                      }
                    ]
  /services/apexrest/v2/projects-summary:
    get:
      tags:
      - Projects
      description: Returns the aggregated summary data for a project or set of projects. Leave the projectID parameter blank to include all accessible projects across your account and any related sub- accounts.
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`\n"
        required: true
        schema:
          type: string
      - name: projectId
        in: query
        description: "A single or comma separated list of Project IDs (15 or 18 digit Salesforce ID, starting a04)"
        required: false
        schema:
          pattern: "^a04[\\da-zA-Z]{12,15}(,a04[\\da-zA-Z]{12,15})*$"
          type: string
      responses:
        "200":
          description: API Answer
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/inline_response_200_4"
              examples:
                example1:
                  value: "{\n  \"targetSLEV\": 1500000,\n  \"progressAgainstTargets\": 76.8,\n  \"numberOfProjects\": 7,\n  \"contractValue\": 5000000,\n  \"actualSLEV\": 987000\n}                   "
      servers:
      - url: https://socialvalueportal.my.salesforce.com
  /services/apexrest/v2/projects:
    get:
      tags:
      - Projects
      description: "Returns a list of project details for a specific project, or for all projects belonging to an account and related child sub-accounts. At least one ID (Project or Account) must be provided."
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`\n"
        required: true
        schema:
          type: string
      - name: accountId
        in: query
        description: "A single or comma separated list of Account IDs (15 or 18 digit Salesforce ID, starting 001)"
        required: false
        schema:
          type: string
      - name: projectId
        in: query
        description: "A single or comma separated list of Project IDs (15 or 18 digit Salesforce ID, starting a04)"
        required: false
        schema:
          type: string
      responses:
        "200":
          description: API Answer
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/inline_response_200_5"
              examples:
                example1:
                  value: |-
                    [
                      {
                          "verificationStatus": false,
                          "type": "Manage",
                          "tomsSet": "National TOMs",
                          "targetSLEV": 0,
                          "status": "Manage",
                          "reference": "6E0-0000-Ls8ic",
                          "procurementManager": "0036E00001U9xfiQAB",
                          "primaryContractManager": null,
                          "postCode": "B1 1BN",
                          "name": "Birmingham Office",
                          "location": [
                              -1.900895,
                              52.476573
                          ],
                          "industryName": "Construction",
                          "id": "a046E00000Ls8icQAE",
                          "externalProjectId": null,
                          "contractValue": 0,
                          "actualSLEV": 0,
                          "accountName": "Acme Constuction Ltd",
                          "accountId": "0018E00001bH7NK"
                      }
                    ]
    put:
      tags:
      - Projects
      description: Allows the update of project(s) details or status. This operation updates multiple project attributes based on the provided project ID.
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`\n"
        required: true
        schema:
          type: string
      - name: Content-Type
        in: header
        description: Specifies the media type of the request body.
        required: true
        schema:
          type: string
          default: application/json
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/v2_Projects_post_body"
            examples:
              example1:
                value:
                - Id: a04Vd000000IGcbIAG
                  AccountID: 0013M00001PsCbpQAF
                  Name: New Project 1
                  ExternalProjectId: MyCompany-Ref00001
                  Type: Manage
                  PostCode: SE1 7TP
                  Industry: a0H3M000007uS3eFAE
                  TOMsSet: a003M000004OfBrPAK
                  ReportingStartDate: 20/12/2023
                  ReportingEndDate: 20/12/2025
                  ReportingFrequency: Annual
                  ContractExtension: "false"
                  ContractExtensionNotes: TestNotes
                  SVWeighting: "10"
                  QualitativeSVWeighting: "50"
                  QuantitativeSVWeighting: "50"
                  tomsPrioritisation: "true"
                  PartOfFramework: "false"
                  ContainsLots: "false"
                  EstimatedContractValue: "250000"
                  TargetSubmissionDate: 05/06/2024
                  TargetSubmissionTime: "12.00"
                  ProcurementManager: 0033M00001KkYUVLA3
                  PrimaryContractManager: 0033M00001KkYUVLA3
                  LocalDefinition: Within a 20 mile radius of the postcode
        required: true
      responses:
        "200":
          description: Successfully updated project(s).
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/inline_response_200_6"
              examples:
                example1:
                  value:
                  - a04Vd000000IGcbIAG
    post:
      tags:
      - Projects
      description: |
        Allows the creation of project(s).
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`\n"
        required: true
        schema:
          type: string
      - name: Content-Type
        in: header
        description: Specifies the media type of the request body.
        required: true
        schema:
          type: string
          default: application/json
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/v2_Projects_body"
            examples:
              example1:
                value: "[ { \"AccountID\": \"0013M00001PsCbpQAF\", \"Name\": \"New Project 1\", \"ExternalProjectId\": \"YourRef-0001\", \"Type\": \"Manage\", \"PostCode\": \"SE1 7TP\", \"Industry\": \"a0H3M000007uC3eUAE\", \"TOMsSet\": \"a003M000004OfXrQAK\", \"ReportingStartDate\": \"20/12/2023\", \"ReportingEndDate\": \"20/12/2025\", \"ReportingFrequency\": \"Annual\", \"Contract Extension\": \"false\", \"Contract Extension Notes\": \"TestNotes\", \"SVWeighting\": \"\", \"QualSVWeighting\": \"\", \"QuantSVWeighting\": \"\", \"TOMsPriorisation\": \"true\", \"PartOfFramework\": \"false\", \"ContainsLots\": \"false\", \"EstimatedContractValue\": \"60\", \"Target Submission Date\": \"01/06/2024\", \"Target Submission Time\": \"19.00\", \"ProcurementManager\": \"0033M00001KkYUVQA3\", \"PrimaryContractManager\": \"0033M00001KkYUVQA3\", \"LocalDefinition\": \"Within a 20 mile radius of the postcode\" }, { \"AccountID\": \"0013M00001PsCbpQAF\", \"Name\": \"New Project 2\", \"ExternalProjectId\": \"YourRef-0002\", \"Type\": \"Manage\", \"PostCode\": \"SE1 7TP\", \"Industry\": \"a0H3M000007uC3eUAE\", \"TOMsSet\": \"a003M000004OfXrQAK\", \"ReportingStartDate\": \"20/12/2023\", \"ReportingEndDate\": \"20/12/2025\", \"ReportingFrequency\": \"Annual\", \"Contract Extension\": \"false\", \"Contract Extension Notes\": \"TestNotes\", \"SVWeighting\": \"\", \"QualSVWeighting\": \"\", \"QuantSVWeighting\": \"\", \"TOMsPriorisation\": \"true\", \"PartOfFramework\": \"false\", \"ContainsLots\": \"false\", \"EstimatedContractValue\": \"60\", \"Target Submission Date\": \"01/06/2024\", \"Target Submission Time\": \"19.00\", \"ProcurementManager\": \"0033M00001KkYUVQA3\", \"PrimaryContractManager\": \"0033M00001KkYUVQA3\", \"LocalDefinition\": \"Within a 20 mile radius of the postcode\" } ] "
      responses:
        "200":
          description: API Answer
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/inline_response_200_5"
              examples:
                example1:
                  value: "[\n  {\n      \"name\": \"Test Create Project 1\",\n      \"id\": \"a048E00000Ltp4GQAR\",\n      \"externalProjectId\": \"EXT-010201\"\n  },\n  {\n      \"name\": \"Test Create Project 2\",\n      \"id\": \"a048E00000Ltp4GQAR\",\n      \"externalProjectId\": \"EXT-010202\"\n  },\n  {\n      \"name\": \"Test Create Project 3\",\n      \"id\": \"a048E00000Ltp4GQAR\",\n      \"externalProjectId\": \"EXT-010203\"\n  }        \n]"
      servers:
      - url: https://socialvalueportal.my.salesforce.com
  /services/apexrest/v2/projects-related-lists:
    get:
      tags:
      - Project Data
      description: "Returns a list of project records along with associated data for a specified project, or belonging to an account. This includes a full list of all measures included in the TOM set related to the Project, and the amount committed or delivered against each measure"
      parameters:
      - name: Authorization
        in: header
        description: "Required Bearer token for accessing the endpoint. \nFormat: `Bearer {token}`\n"
        required: true
        schema:
          type: string
      - name: accountId
        in: query
        description: A single or comma separated list of Account ID's
        required: false
        schema:
          type: string
      - name: projectId
        in: query
        description: A single or comma separated list of Project ID's
        required: false
        schema:
          type: string
      responses:
        "200":
          description: A list of projects with detailed information.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/v2_ProjectRelatedResponse"
              examples:
                example1:
                  value: "[ { \"validated\": \"false\", \"type\": \"Manage\", \"tomsSetId\": \"a003M000004OfXrQAK\", \"tomsSet\": \"National TOMs\", \"status\": \"Live\", \"socialValues\": [ { \"supplier\": \"Test Client 2\", \"status\": \"Delivery\", \"name\": \"Target and Delivery Demo\", \"id\": \"a053M000002BhnWQAS\", \"contractValue\": \"670000\", \"answers\": [ { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"LV\", \"reference\": \"NT29\", \"proxyValue\": \"30353.000000000\", \"periodDateAnswers\": [ { \"verified\": \"false\", \"periodStartDate\": \"2023-12-01\", \"periodEndDate\": \"2023-12-31\", \"id\": \"a0iVd00000007sjIAA\", \"actualSlev\": \"2701417.00\", \"actualNumber\": \"89.00\", \"actualDescription\": \"TestDelEvid\" } ], \"outcome\": \"More local people in employment\", \"nationalTomsRef\": \"NT1\", \"measure\": \"No. of local direct employees (FTE) hired or retained (for re-tendered contracts) on contract for one year or the whole duration of the contract, whichever is shorter\", \"kpi\": \"Local Employment (no.)\", \"id\": \"a023M000006S0FtQAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"698119.00\", \"targetNumber\": \"23.00\", \"targetDescription\": \"TestDescJan\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"LV\", \"reference\": \"NT1a\", \"proxyValue\": \"30353.000000000\", \"periodDateAnswers\": null, \"outcome\": \"More local people in employment\", \"nationalTomsRef\": \"NT1a\", \"measure\": \"No. of local direct employees (FTE) which are TUPE transfers retained on contract for one year or the whole duration of the contract, whichever is shorter (re-tendered contracts only - to be used at Measurement)\", \"kpi\": \"Local Employment (no.)\", \"id\": \"a023M000006S0FuQAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"30353.00\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"LV\", \"reference\": \"RE1a\", \"proxyValue\": \"30353.000000000\", \"periodDateAnswers\": null, \"outcome\": \"More local people in employment\", \"nationalTomsRef\": \"NT1b\", \"measure\": \"No. of residents (FTE) from the listed sub-localities employed directly or through the supply chain as a result of your procurement requirements on the contract for one year or the whole duration of the contract, whichever is shorter (see sub-localities listed in LISTNT1b)\", \"kpi\": \"Local Employment (no.)\", \"id\": \"a023M000006S0FvQAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"30353.00\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc3\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"LV\", \"reference\": \"RE1b\", \"proxyValue\": \"30353.000000000\", \"periodDateAnswers\": null, \"outcome\": \"More local people in employment\", \"nationalTomsRef\": \"NT1c\", \"measure\": \"No. of local people (FTE) on contract for one year or the whole duration of the contract, whichever is shorter, employed through the supply chain as a result of your procurement requirements\", \"kpi\": \"Local Employment (no.)\", \"id\": \"a023M000006S0FwQAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"30353.00\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc4\" }, { \"unit\": \"%\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"LV\", \"reference\": \"RE2\", \"proxyValue\": \"0E-9\", \"periodDateAnswers\": null, \"outcome\": \"More local people in employment\", \"nationalTomsRef\": \"NT2\", \"measure\": \"Percentage of local employees (FTE) on contract\", \"kpi\": null, \"id\": \"a023M000006S0FxQAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"0.00\", \"targetNumber\": \"13.00\", \"targetDescription\": \"TestDesc5\" }, { \"unit\": \"£\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE3\", \"proxyValue\": \"1.000000000\", \"periodDateAnswers\": null, \"outcome\": \"More local people in employment\", \"nationalTomsRef\": \"RE3\", \"measure\": \"Employers fairs held to encourage local employment in the area\", \"kpi\": null, \"id\": \"a023M000006S0FyQAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"345.00\", \"targetNumber\": \"345.00\", \"targetDescription\": \"TestDesc6\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE4\", \"proxyValue\": \"19023.477000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT3\", \"measure\": \"No. of employees (FTE) hired on the contract who are long term unemployed (unemployed for a year or longer) as a result of a recruitment programme\", \"kpi\": \"Long Term Unemployed (no.)\", \"id\": \"a023M000006S0FzQAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"19023.48\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc7\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"NT3a\", \"proxyValue\": \"19023.477000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT3a\", \"measure\": \"No. of armed forces veterans employees (FTE) hired on the contract as a result of a recruitment programme who are long term unemployed (unemployed for a year or longer) and are facing specific barriers to transitioning to civilian employment that do not qualify them as disabled (e.g. long term service)\", \"kpi\": \"Long Term Unemployed (no.)\", \"id\": \"a023M000006S0G0QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"38046.95\", \"targetNumber\": \"2.00\", \"targetDescription\": \"TestDesc8\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"NT3b\", \"proxyValue\": \"19023.477000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT3b\", \"measure\": \"No. of homeless employees (FTE) hired on the contract as a result of a recruitment programme\", \"kpi\": null, \"id\": \"a023M000006S0G1QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"19023.48\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc9\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"NT3c\", \"proxyValue\": \"19023.477000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT3c\", \"measure\": \"No. of mothers returning to work (FTE) hired on the contract as a result of a recruitment programme who are long-term unemployed (unemployed for a year or longer) - (when the mother is the primary carer)\", \"kpi\": null, \"id\": \"a023M000006S0G2QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"57070.43\", \"targetNumber\": \"3.00\", \"targetDescription\": \"TestDesc10\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"NT3d\", \"proxyValue\": \"19023.477000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT3d\", \"measure\": \"No. of survivors of modern slavery employees (FTE) hired on the contract as a result of a recruitment programme\", \"kpi\": null, \"id\": \"a023M000006S0G3QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"0.00\", \"targetNumber\": \"0.00\", \"targetDescription\": \"TestDesc11\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE5\", \"proxyValue\": \"13734.005000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT4\", \"measure\": \"No. of employees (FTE) hired on the contract who are Not in Employment, Education, or Training (NEETs) as a result of a recruitment programme\", \"kpi\": null, \"id\": \"a023M000006S0G4QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"13734.01\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc12\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"NT4a\", \"proxyValue\": \"13734.005000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT4a\", \"measure\": \"No. of 16-25 y.o. care leavers (FTE) hired on the contract as a result of a recruitment programme\", \"kpi\": null, \"id\": \"a023M000006S0G5QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"13734.01\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc13\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE6\", \"proxyValue\": \"23169.815000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT5\", \"measure\": \"No. of 18+ y.o. employees (FTE) hired on the contract who are rehabilitating or ex offenders as a result of a recruitment programme\", \"kpi\": null, \"id\": \"a023M000006S0G6QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"23169.82\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc14\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"NT5a\", \"proxyValue\": \"22213.200000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT5a\", \"measure\": \"No. of 18-24 y.o. employees (FTE) hired on the contract who are rehabilitating young offenders as a result of a recruitment programme\", \"kpi\": null, \"id\": \"a023M000006S0G7QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"22213.20\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc15\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE7\", \"proxyValue\": \"15188.633000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT6\", \"measure\": \"No. of disabled employees (FTE) hired on the contract as a result of a recruitment programme\", \"kpi\": \"Disabled People (no.)\", \"id\": \"a023M000006S0G8QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"15188.63\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc16\" }, { \"unit\": \"no. people FTE\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"NT6a\", \"proxyValue\": \"15188.633000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT6a\", \"measure\": \"No. of armed forces veterans employees (FTE) hired on the contract as a result of a recruitment programme who are disabled and are facing specific barriers to transitioning to civilian employment (e.g. physical injury, medical discharge, psychological condition) No. of armed forces veterans employees (FTE) hired on the contract as a result of a recruitment programme\", \"kpi\": null, \"id\": \"a023M000006S0G9QAK\", \"attachmentCount\": \"0\", \"targetSlev\": \"15188.63\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc17\" }, { \"unit\": \"%\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE57\", \"proxyValue\": \"0E-9\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"RE57\", \"measure\": \"Percentage of women (FTE) hired on the contract\", \"kpi\": null, \"id\": \"a023M000006S0GAQA0\", \"attachmentCount\": \"0\", \"targetSlev\": \"0.00\", \"targetNumber\": \"6.00\", \"targetDescription\": \"TestDesc18\" }, { \"unit\": \"%\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE58\", \"proxyValue\": \"0E-9\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"RE58\", \"measure\": \"Percentage of employees (FTE) BAME hired on the contract\", \"kpi\": null, \"id\": \"a023M000006S0GBQA0\", \"attachmentCount\": \"0\", \"targetSlev\": \"0.00\", \"targetNumber\": \"10.00\", \"targetDescription\": \"TestDesc19\" }, { \"unit\": \"Y/N\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE71\", \"proxyValue\": \"0E-9\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"RE71\", \"measure\": \"Specific initiatives or recruitment programmes for women run for the contract (Y/N)\", \"kpi\": null, \"id\": \"a023M000006S0GCQA0\", \"attachmentCount\": \"0\", \"targetSlev\": \"0.00\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc20\" }, { \"unit\": \"Y/N\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE72\", \"proxyValue\": \"0E-9\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"RE72\", \"measure\": \"Specific initiatives or recruitment programmes for BAME run for the contract (Y/N)\", \"kpi\": null, \"id\": \"a023M000006S0GDQA0\", \"attachmentCount\": \"0\", \"targetSlev\": \"0.00\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc21\" }, { \"unit\": \"no. hrs (total session duration)*no. attendees\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE8\", \"proxyValue\": \"145.480000000\", \"periodDateAnswers\": null, \"outcome\": \"More opportunities for disadvantaged people\", \"nationalTomsRef\": \"NT7\", \"measure\": \"No. of hours of support into work provided to unemployed people through career mentoring, including mock interviews, CV advice, and careers guidance -(over 24 y.o.)\", \"kpi\": \"Career Support Sessions (hrs)\", \"id\": \"a023M000006S0GEQA0\", \"attachmentCount\": \"0\", \"targetSlev\": \"145.48\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc22\" }, { \"unit\": \"no. weeks\", \"theme\": \"Jobs: Promote Local Skills and Employment\", \"socialOrLocal\": \"SV\", \"reference\": \"RE11\", \"proxyValue\": \"258.446000000\", \"periodDateAnswers\": null, \"outcome\": \"Improved skills\", \"nationalTomsRef\": \"NT9\", \"measure\": \"No. of weeks of training opportunities on the contract (BTEC, City & Guilds, NVQ, HNC) that have either been completed during the year, or that will be supported by the organisation until completion in the following years - Level 2,3, or 4+\", \"kpi\": \"Training Opportunities (weeks)\", \"id\": \"a023M000006S0GFQA0\", \"attachmentCount\": \"0\", \"targetSlev\": \"258.45\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc23\" }, { \"unit\": \"£\", \"theme\": \"Growth: Supporting Growth of Responsible Regional Business\", \"socialOrLocal\": \"LV\", \"reference\": \"NT19\", \"proxyValue\": \"258.446000000\", \"periodDateAnswers\": null, \"outcome\": \"Improved skills\", \"nationalTomsRef\": \"NT19\", \"measure\": \"Total amount (£) spent through contract with LOCAL micro, small and medium enterprises (MSMEs)\", \"kpi\": \"Training Opportunities (weeks)\", \"id\": \"a023M000006S0GGQA0\", \"attachmentCount\": \"0\", \"targetSlev\": \"258.45\", \"targetNumber\": \"1.00\", \"targetDescription\": \"TestDesc24\" } ] } ], \"postCode\": \"B1 1BN\", \"name\": \"Birmingham Office\", \"location\": [ null, null ], \"industryId\": \"a0H3M000007uCXFUA2\", \"industry\": \"Construction\", \"id\": \"a043M000002KiazQAC\", \"externalProjectId\": null, \"collection\": null, \"accounts\": { \"subAccount4\": null, \"subAccount3\": null, \"subAccount2\": null, \"subAccount1\": null, \"masterAccount\": \"Test Client 2\" } } ]"
    put:
      tags:
      - Project Data
      description: Allows updating or inserting project records and their related data.
      requestBody:
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/v2_ProjectRelated_body"
            examples:
              example1:
                value:
                - id: a0426000005nv4gAAA
                  measures:
                  - measureRef: NT1
                    deliveryDate: 12/01/2021
                    numberDelivered: "89"
                    deliveryEvidence: TestDelEvidJan
                  - measureRef: NT1a
                    deliveryDate: 07/04/2021
                  - measureRef: NT18
                    deliveryDate: 12/06/2021
      responses:
        "200":
          description: API Answer
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/inline_response_200_7"
              examples:
                example1:
                  value:
                  - a0iSd000000SuGpIAL
      servers:
      - url: https://socialvalueportal.my.salesforce.com
    servers:
    - url: https://socialvalueportal.my.salesforce.com
components:
  schemas:
    v2_Accounts:
      type: object
      properties:
        ultimateParent:
          pattern: "^001[\\da-zA-Z]{12,15}(,001[\\da-zA-Z]{12,15})*$"
          type: string
          description: "A comma-separated list of 15 or 18 digit Salesforce IDs for the account, each starting with 001. Example: '001ABC123456789,001XYZ987654321'."
        postCode:
          pattern: "^[A-Z0-9]{2,4}[A-Z0-9]{2,3}$"
          type: string
          description: Postal code of the account location.
        parentId:
          pattern: "^001[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for the parent of the returned account, starting with 001. Example: '001ABC123456789'."
        membershipStart:
          type: string
          description: Start date of membership (yyyy-mm-dd)
          format: date
        membershipEnd:
          type: string
          description: End date of membership (yyyy-mm-dd)
          format: date
        location:
          $ref: "#/components/schemas/v2_Accounts_location"
        id:
          pattern: "^001[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for returned account, starting with 001. Example: '001ABC123456789'."
        accountQuestionnaire:
          type: string
          description: Name of the default questionnaire associated with the returned account.
        accountName:
          type: string
          description: Name of the returned account.
    v2_Account-hierarchies:
      type: object
      properties:
        parentName:
          type: string
          description: Name of parent of returned account.
        parentId:
          pattern: "^001[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for the parent of the returned account, starting with 001. Example: '001ABC123456789'."
        name:
          type: string
          description: Name of returned account.
        id:
          pattern: "^001[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for returned account, starting with 001. Example: '001ABC123456789'."
    v2_Projects_body:
      required:
      - AccountID
      - ExternalProjectId
      - Industry
      - Name
      - PostCode
      - ReportingEndDate
      - ReportingFrequency
      - ReportingStartDate
      - TOMsSet
      - Type
      type: array
      properties:
        AccountID:
          pattern: "^001[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the account, starting with 001."
        Name:
          type: string
          description: Name of the project.
        ExternalProjectId:
          type: string
          description: A unique ID for the project that matches an ID in your system.
        Type:
          type: string
          description: "Type of the project, which determines the focus on social value aspects."
          enum:
          - Bid
          - Measure
          - Manage
        PostCode:
          pattern: "^[A-Z0-9]{2,4}[A-Z0-9]{2,3}$"
          type: string
          description: A valid UK postcode with spaces removed.
        Industry:
          pattern: "^a0H[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the industry, starting with a0H."
        TOMsSet:
          pattern: "^a00[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the TOMs set, starting with a00."
        ReportingStartDate:
          type: string
          description: Start date for reporting on the project ('dd/mm/yyyy').
          format: date
        ReportingEndDate:
          type: string
          description: End date for reporting on the project ('dd/mm/yyyy').
          format: date
        ReportingFrequency:
          type: string
          description: Frequency of reporting for the project.
          enum:
          - Monthly
          - Quarterly
          - Annual
          - One-off
          - Six-Monthly
          - Irregular
        ProcurementManager:
          pattern: "^003[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the procurement manager, starting with 003."
        PrimaryContractManager:
          pattern: "^003[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the primary contract manager, starting with 003."
        LocalDefinition:
          type: string
          description: Local definition determining the geographical scope of the project's impact.
          enum:
          - Within the boundaries of the local authority
          - Within a 10 mile radius of the postcode
          - Within a 15 mile radius of the postcode
          - Within a 20 mile radius of the postcode
          - Other
        ContractExtension:
          type: boolean
          description: Whether there is an extension to the contract.
        ContractExtensionNotes:
          type: string
          description: Notes regarding the contract extension.
        SVWeighting:
          maximum: 100
          minimum: 0
          type: number
          description: "Social value weighting that has been allocated as part of the overall quality/price matrix for this procurement, expressed as a percentage from 0 to 100."
        QualSVWeighting:
          maximum: 100
          minimum: 0
          type: number
          description: Qualitative social value weighting. The sum of the values inside Qualitative SV Weighting and Quantitative SV Weighting must equal 100.
        QuantSVWeighting:
          maximum: 100
          minimum: 0
          type: number
          description: Quantitative social value weighting. The sum of the values inside Qualitative SV Weighting and Quantitative SV Weighting must equal 100.
        TOMsPrioritisation:
          type: boolean
          description: Indicator if TOMs are prioritized in this project.
        PartOfFramework:
          type: boolean
          description: Whether the project is part of a framework.
        ContainsLots:
          type: boolean
          description: Whether the project contains multiple lots.
        EstimatedContractValue:
          type: string
          description: Estimated contract value of the project.
        TargetSubmissionDate:
          type: string
          description: Target date for project submission ('dd/mm/yyyy').
          format: date
        TargetSubmissionTime:
          pattern: "^([01]?[0-9]|2[0-3]).[0-5][0-9]$"
          type: string
          description: "Target time for project submission, in 24-hour format, with a period separator."
      items:
        $ref: "#/components/schemas/v2_Projects_body"
    v2_Projects_post_body:
      required:
      - Id
      type: array
      properties:
        Id:
          pattern: "^a04[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the Project to be updated, starting with a04."
        AccountID:
          pattern: "^001[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the account, starting with 001."
        Name:
          type: string
          description: Name of the project.
        ExternalProjectId:
          type: string
          description: A unique ID for the project that matches an ID in your system.
        Type:
          type: string
          description: "Type of the project, which determines the focus on social value aspects."
          enum:
          - Bid
          - Measure
          - Manage
        PostCode:
          pattern: "^[A-Z0-9]{2,4}[A-Z0-9]{2,3}$"
          type: string
          description: A valid UK postcode with spaces removed.
        Industry:
          pattern: "^a0H[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the industry, starting with a0H."
        TOMsSet:
          pattern: "^a00[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the TOMs set, starting with a00."
        ReportingStartDate:
          type: string
          description: Start date for reporting on the project ('dd/mm/yyyy').
          format: date
        ReportingEndDate:
          type: string
          description: End date for reporting on the project ('dd/mm/yyyy').
          format: date
        ReportingFrequency:
          type: string
          description: Frequency of reporting for the project.
          enum:
          - Monthly
          - Quarterly
          - Annual
          - One-off
          - Six-Monthly
          - Irregular
        ProcurementManager:
          pattern: "^003[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the procurement manager, starting with 003."
        PrimaryContractManager:
          pattern: "^003[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the primary contract manager, starting with 003."
        LocalDefinition:
          type: string
          description: Local definition determining the geographical scope of the project's impact.
          enum:
          - Within the boundaries of the local authority
          - Within a 10 mile radius of the postcode
          - Within a 15 mile radius of the postcode
          - Within a 20 mile radius of the postcode
          - Other
        ContractExtension:
          type: boolean
          description: Whether there is an extension to the contract.
        ContractExtensionNotes:
          type: string
          description: Notes regarding the contract extension.
        SVWeighting:
          maximum: 100
          minimum: 0
          type: number
          description: "Social value weighting that has been allocated as part of the overall quality/price matrix for this procurement, expressed as a percentage from 0 to 100."
        QualSVWeighting:
          maximum: 100
          minimum: 0
          type: number
          description: Qualitative social value weighting. The sum of the values inside Qualitative SV Weighting and Quantitative SV Weighting must equal 100.
        QuantSVWeighting:
          maximum: 100
          minimum: 0
          type: number
          description: Quantitative social value weighting. The sum of the values inside Qualitative SV Weighting and Quantitative SV Weighting must equal 100.
        TOMsPrioritisation:
          type: boolean
          description: Indicator if TOMs are prioritized in this project.
        PartOfFramework:
          type: boolean
          description: Whether the project is part of a framework.
        ContainsLots:
          type: boolean
          description: Whether the project contains multiple lots.
        EstimatedContractValue:
          type: string
          description: Estimated contract value of the project.
        TargetSubmissionDate:
          type: string
          description: Target date for project submission ('dd/mm/yyyy').
          format: date
        TargetSubmissionTime:
          pattern: "^([01]?[0-9]|2[0-3]).[0-5][0-9]$"
          type: string
          description: "Target time for project submission, in 24-hour format, with a period separator."
      items:
        $ref: "#/components/schemas/v2_Projects_post_body"
    v2_ProjectRelated_body:
      required:
      - id
      type: array
      properties:
        id:
          pattern: "^a04[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the project, starting with a04."
        measures:
          $ref: "#/components/schemas/v2_ProjectRelated_body_measures"
      items:
        $ref: "#/components/schemas/v2_ProjectRelated_body"
    v2_ProjectRelatedResponse:
      type: array
      properties:
        id:
          pattern: "^004[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for the project, starting with a04."
        name:
          type: string
          description: Name of the project.
        postCode:
          pattern: "^[A-Z0-9]{2,4}[A-Z0-9]{2,3}$"
          type: string
          description: Postal code.
        validated:
          type: boolean
          description: Has data for the project been validated?
        externalProjectId:
          type: string
          description: A unique ID for the project that matches an ID in your system.
        type:
          type: string
          description: "Type of the project, which determines the whether it records Social Value commitments, delivered Social Value, or both."
          enum:
          - Bid
          - Measure
          - Manage
        tomsSetId:
          pattern: "^a00[\\da-zA-Z]{12,15}$"
          type: string
          description: "A 15 or 18 digit Salesforce ID for the TOMs set, starting with a00."
        tomsSet:
          type: string
          description: Name of TOM Set used.
        status:
          type: string
          description: Status of the Project. Demo projects are not included in aggregate total Social Value headlines.
          enum:
          - Live
          - Demo
          - Closed
        location:
          $ref: "#/components/schemas/v2_ProjectRelatedResponse_location"
        industryId:
          pattern: "^a0H[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for the industry, starting with a0H."
        collection:
          pattern: "^a0L[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID showing the Project Collection, starting with a0L. A collection may be used to group together different project under different sub-accounts for reporting."
        accounts:
          $ref: "#/components/schemas/v2_ProjectRelatedResponse_accounts"
        socialValues:
          $ref: "#/components/schemas/v2_ProjectRelatedResponse_socialValues"
      items:
        $ref: "#/components/schemas/v2_ProjectRelatedResponse"
    oauth2_token_body:
      required:
      - assertion
      - grant_type
      type: object
      properties:
        grant_type:
          type: string
          description: "Specifies the OAuth grant type. For JWT Bearer, this must be 'urn:ietf:params:oauth:grant-type:jwt-bearer'."
          enum:
          - urn:ietf:params:oauth:grant-type:jwt-bearer
        assertion:
          type: string
          description: "The JWT token assertion, used to authenticate the client and request the token."
    inline_response_200:
      type: object
      properties:
        access_token:
          type: string
          description: The access token issued by the authorization server.
        scope:
          type: string
          description: The scope of the access granted by the token.
        instance_url:
          type: string
          description: The base URL to use for requests to the API.
          format: uri
        id:
          type: string
          description: The identifier URL for the token.
          format: uri
        token_type:
          type: string
          description: The type of token issued.
    inline_response_400:
      type: object
      properties:
        error:
          type: string
          description: "The error type (e.g., invalid_grant, unsupported_grant_type)."
        error_description:
          type: string
          description: A human-readable description of the error
    inline_response_200_1:
      type: object
      properties:
        year:
          type: string
          description: Reporting year for TOM set proxy values. This must match the year on the industry record specified for a Project.
        name:
          type: string
          description: Name of returned TOM set.
        id:
          pattern: "^a00[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for the returned TOM set, starting with a00. Example: 'a00ABC123456789'."
    inline_response_200_2:
      type: object
      properties:
        year:
          type: string
          description: Reporting year for data linked to the returned industry record
        industryName:
          type: string
          description: Name of the returned industry.
        id:
          pattern: "^a0H[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for the returned industry, starting with a0H. Example: 'a0HABC123456789'."
    inline_response_200_3:
      type: object
      properties:
        id:
          pattern: "^003[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for returned contact record, starting with 003. Example: '003ABC123456789'."
        email:
          type: string
        name:
          pattern: "^a0H[\\da-zA-Z]{12,15}$"
          type: string
          description: SF ID used to identify Industry. This is required for new project creation
        accountName:
          type: string
          description: Reporting year for industry data
        accountId:
          pattern: "^001[\\da-zA-Z]{12,15}$"
          type: string
          description: Reporting year for industry data
    inline_response_200_4:
      type: object
      properties:
        targetSLEV:
          type: number
          description: The targeted or committed Social and Local Economic Value (SLEV) for the project(s) in monetary units.
          format: double
        progressAgainstTargets:
          type: number
          description: Percentage of the progress made against the targets.
          format: double
        numberOfProjects:
          type: integer
          description: Total number of projects included in the summary.
        contractValue:
          type: number
          description: Total contract value of the projects in monetary units.
          format: double
        actualSLEV:
          type: number
          description: Actual delivered Social and Local Economic Value (SLEV) achieved by the project(s) in monetary units.
          format: double
    inline_response_200_5:
      type: object
      properties:
        name:
          type: string
          description: Confirmation of the name of the created project
        id:
          pattern: "^a04[\\da-zA-Z]{12,15}(,a04[\\da-zA-Z]{12,15})*$"
          description: "A single or comma separated list of 15 or 18 digit Salesforce IDs for the project, starting with a04. Example: '001ABC123456789,001XYZ987654321'."
        externalProjectId:
          type: string
          description: Confirmation of your unique reference for the project.
    inline_response_200_6:
      type: object
      properties:
        id:
          pattern: "^a04[\\da-zA-Z]{12,15}(,a04[\\da-zA-Z]{12,15})*$"
          description: "A single or comma separated list of 15 or 18 digit Salesforce IDs for the project, starting with a04. Example: '001ABC123456789,001XYZ987654321'."
    inline_response_200_7:
      type: object
      properties:
        id:
          pattern: "^a0i[\\da-zA-Z]{12,15}(,a04[\\da-zA-Z]{12,15})*$"
          description: "A single or comma separated list of 18 digit Salesforce IDs for the measure response for that period, starting with a0i."
    v2_Accounts_location:
      type: object
      properties:
        latitude:
          type: number
          description: Latitude of the account location.
          format: float
        longitude:
          type: number
          description: Longitude of the account location.
          format: float
    v2_ProjectRelated_body_measures:
      required:
      - deliveryDate
      - measureRef
      type: object
      properties:
        measureRef:
          type: string
          description: Reference for the TOM system measure e.g. NT1. This must exist in the measure set/questionnaire linked to the project.
        deliveryDate:
          type: string
          description: Date of delivery (dd/mm/yyy).
        numberDelivered:
          type: string
          description: Delivered Social Value for this measure.
        deliveryEvidence:
          type: string
          description: Evidence provided to demonstrate delivery of the measure.
      description: Committed and/or delivered aggregrated Social Value associated with a specific Social Value measure.
    v2_ProjectRelatedResponse_location:
      type: object
      properties:
        latitude:
          type: number
          format: double
        longitude:
          type: number
          format: double
    v2_ProjectRelatedResponse_accounts:
      type: object
      properties:
        masterAccount:
          type: string
          description: Top level parent account that has access to the project. Sub-accounts sit under this account.
        subAccount1:
          type: string
          description: "First level child account under the Master Account, that has access to the project."
        subAccount2:
          type: string
          description: "Second level child account under the Master Account, that has access to the project."
        subAccount3:
          type: string
          description: "Third level child account under the Master Account, that has access to the project."
        subAccount4:
          type: string
          description: "Fourth level child account under the Master Account, that has access to the project."
    v2_ProjectRelatedResponse_socialValues_answers_periodDateAnswers:
      type: object
      properties:
        id:
          type: string
          description: "An 18 digit Salesforce ID showing the Period Date Answer record, starting with a0i. This is used to aggregate responses for a particular TOM measure against the different time periods set up for the Project."
        verified:
          type: string
          description: Has the evidence provided for the measure relating to this reporting period been verified and validated?
        periodStartDate:
          type: string
          description: Start date of the reporting period for this measure data.
        periodEndDate:
          type: string
          description: End date of the reporting period for this measure data.
        actualSlev:
          type: string
          description: Total Social (and Local Economic) Value delivered for this measure in this reporting period.
        actualNumber:
          type: string
          description: Total amount delivered for this measure in this reporting period.
        actualDescription:
          type: string
          description: Evidence provided for how the measure was delivered in this reporting period.
      description: "Response to the measure, aggregated by period."
    v2_ProjectRelatedResponse_socialValues_answers:
      type: object
      properties:
        unit:
          type: string
          description: Unit of measurement for the measure.
        theme:
          type: string
          description: Theme for the measure being responded to.
        socialOrLocal:
          type: string
          description: Measure designated as contributing to Local Economic Value (LV) or Social Value (SV).
          enum:
          - LV
          - SV
        reference:
          type: string
          description: TOM system reference for the measure.
        proxyValue:
          type: string
          description: Proxy value or social value multiplier applied to this measure.
        targetSlev:
          type: string
          description: Target Social (and Local Economic) Value commitment for this measure in this reporting period.
        targetNumber:
          type: string
          description: Target amount committed for this measure in this reporting period.
        targetDescription:
          type: string
          description: Description of how the target amount committed for this measure in this reporting period will be delivered.
        periodDateAnswers:
          $ref: "#/components/schemas/v2_ProjectRelatedResponse_socialValues_answers_periodDateAnswers"
    v2_ProjectRelatedResponse_socialValues:
      type: object
      properties:
        id:
          pattern: "^a05[\\da-zA-Z]{12,15}$"
          type: string
          description: "An 18 digit Salesforce ID for the industry, starting with a05."
        name:
          type: string
          description: "Name of the record. The default pattern for this is the name of the project, followed by the name of the supplier, separated by a hyphen."
        supplier:
          type: string
          description: Name of the account designated as the supplier for this Social Value record.
        status:
          type: string
          description: "Status of the Social Value record on the project. This will be either Registered or Submitted for a Bid record, Delivery for a record that is being delivered, or Closed for a completed record."
          enum:
          - registered
          - submitted
          - delivery
          - closed
        contractValue:
          type: number
          description: The value of the bid or contract represented by this Social Value record.
        answers:
          $ref: "#/components/schemas/v2_ProjectRelatedResponse_socialValues_answers"
