These are the release notes of the SAP Cloud SDK for JavaScript / TypeScript. You may also be interested in the release notes of the SDK for Java.
Note: The SAP Cloud SDK was previously known as SAP S/4HANA Cloud SDK.
April 9, 2020 - JSDoc API documentation for core | JSDoc API documentation for VDM | > Release blog
withCustomQueryParameters()
.March 26, 2020 - JSDoc API documentation for core | JSDoc API documentation for VDM | > Release blog
HTTP
are expected to contain a url
or URL
property. Note that when retrieving a destination from the destinations
environment variable, all destinations are validated. This validation applies even to destinations that are not read.destinations
environment variable with the same property keys as known from the destination service on SAP Cloud Platform, e.g. now URL
is considered valid in addition to previously only url
.Principal Propagation
as authentication scheme for on-premises connectivity.March 12, 2020 - JSDoc API documentation for core | JSDoc API documentation for VDM | > Release blog
package.json
to use the new packages.@sap/cloud-sdk-util
was renamed to @sap-cloud-sdk/util
@sap/cloud-sdk-analytics
was renamed to @sap-cloud-sdk/analytics
@sap/cloud-sdk-core
was renamed to @sap-cloud-sdk/core
@sap/cloud-sdk-generator
was renamed to @sap-cloud-sdk/generator
@sap/cloud-sdk-test-util
was renamed to @sap-cloud-sdk/test-util
dependencies
, devDependencies
, peerDependencies
in your package.json
.@sap/cloud-sdk-core
) with new one (e.g. @sap-cloud-sdk/core
).^1.18.0
).npm i
).require()
and replace them with new names.package.json
by passing the desired version to the generator as an argument versionInPackageJson
.February 27, 2020 - JSDoc API documentation | > Release blog
PrincipalPropagation
and proxy type OnPremise
(as configured in the SAP Cloud Platform cockpit) will currently throw errors. This can be worked around by setting the authentication type to NoAuthentication
instead.HTTP_PROXY
, HTTPS_PROXY
, http_proxy
, https_proxy
) for destinations configured in VCAP service bindings (e.g. when using SAP Extension Factory).asc
and desc
to be more specific, now returning Order
insteaf of Orderable
.February 13, 2020 - JSDoc API documentation | > Release blog
@sap/cloud-sdk-vdm-*
), new operations in previously existing services, and new entity types. The SDK supports all OData services listed in the SAP API Business Hub for SAP S/4HANA Cloud.http_proxy
and https_proxy
for configuring proxy settings for outbound requests, that do not use the SAP Cloud Connector. The no_proxy
variables can be used to exclude certain destinations from using the proxy. See ProxyConfiguration
for more details..edmx
files that contain entities ending with "Type".January 30, 2020 - JSDoc API documentation | > Release blog
1.17.0
.bool substringof(string po, string p1)
, string substring(string p0, int pos)
and int length(string p0)
. For filtering with those functions use:SomeEntity.filter(length(SomeEntity.FIELD).greaterThan(10));
substringOf(Field,to_SomeEntity/OtherField)
is not supported at this time.filterFunction
factory function to filter using any of the OData v2 filter functions generically:SomeEntity.filter(filterFunction('concat', 'string', 'prefix', SomeEntity.FIELD).equals('prefixSomeName'))
http_proxy
environment variable parsing used by the OData requests. Requests that do not need a proxy will now not be broken due to environment variables (see also known issues).@sap/cloud-sdk-core
module were recorded by analytics instead of the dependencies of the project that installed the SDK.January 16, 2020 - JSDoc API documentation | > Release blog
batch
requests with changeset
did not enforce type safety. Now a batch
can contain only changesets
on entities of the given service instead of entities from different services.HttpRequestConfig
interface which previously used body
instead of data
. This led to data not being added to some HTTP requests.EntityBuilder.fromJson()
method so that passing a JSON object with unexisting attributes is not allowed. For example, { bupa : "1" }
cannot be passed to the method when building a BusinessPartner
entity as the property bupa
does not exist in this entity.December 19, 2019 - JSDoc API documentation | > Release blog
service-mapping.json
file in the VDM generator. It failed on Windows systems due to a hard coded /
.December 5, 2019 - JSDoc API documentation | > Release blog
entityConstructor
, linkedEntity
, fieldName
properties in generated entities to _entityConstructor
, _linkedEntity
, _fieldName
.setLogLevel()
.fieldName
is defined as the name of a property in an entity.esModuleInterop
compilation flag.contains()
function from filter expressions in the OData request builder.November 21, 2019 - JSDoc API documentation | > Release blog
@sap/cloud-sdk-analytics
to provide insights into the SDK usage for further improving the SDK in the future.EntityType_<number>
might now have a different name when regenerated./
.sanitizeDestination
led to an error when called multiple times on the same destination object.November 7, 2019 - JSDoc API documentation | > Release blog
@sap-cloud-sdk/cli
on the central registry npmjs.com. The CLI makes it easy to add the SAP Cloud SDK for JavaScript to an existing project and simplifies several other tasks when building applications on SAP Cloud Platform.npm install @sap-cloud-sdk/cli
).sap-cloud-sdk --help
after installing.OAuth2SAMLBearerAssertion
authentication type that include a property SystemUser
. The system user will be used instead of the currently logged in user to retrieve an access token to the destination. That is, no principal propagation takes place. As a consequence, no user JWT is required.DestinationOptions
in execute
method of OData VDM request builders. The type used previously was overly restrictive, which prevented passing of valid objects like a selectionStrategy
, even though the code actually handles it.systems.json
and credentials.json
files, respectively.October 24, 2019 - JSDoc API documentation | > Release blog
--generateCSN=true
. The default value is false.my-service
the CSN will be in my-service/my-service-csn.json
.October 10, 2019 - JSDoc API documentation | > Release blog
@sap/cloud-sdk-generator
) due to technical reasons. 1.10.0 remains the current version of the generator. As a consequence, the new features of the OData client mentioned below (batch and CSN files) are not yet available for custom OData clients generated by the generator.
Bearer
" was spelled in title case. Now, retrieveJwt
does a case insensitive check for "bearer
". That means, "bearer" and "Bearer" are now equally supported as correct authorization header.batch
that each module for a OData service exposes (see example for business partner service) to construct a batch request. Pass prepared query and by-key request builders as parameters to the method (instead of executing them), as well as change sets.changeset
that each module for a OData service exposes (see example for business partner service) to construct a change set. Pass prepared create, update, and delete request builders as parameters to the method (instead of executing them). Then, pass the constructed change set to the batch
method.execute
, which returns a promise of a list of BatchResponse
.BatchResponse
is a union type, representing the response of an indiviual retrieve request or change set that was passed to the batch request. Use isSuccess
to verify that the retrieve request or change set was successful. Then, use a type assertion like response as ReadResponse
based on your knowledge of the expected response to further work with the response.node_modules
after npm-installing an SDK module.verifyJwt
method, no action is required.fromJson
method of entity builders to properly parse a JSON in the notation used elsewhere in the SDK, with links and attributes in camel-case."strictNullChecks": true
is set in the tsconfig.json
file of the project.September 26, 2019 - JSDoc API documentation | > Release blog
Tenant
object from a JWT with the new method tenantFromJwt
.User
object from a JWT with the new method userFromJwt
.September 12, 2019 - JSDoc API documentation | > Release blog
ClientCertificateAuthentication
.replaceWholeEntityWithPut
method.GetByKeyRequestBuilder
).ignoreVersionIdentifier
method.x-csrf-token
header was ignored by the destination. Now, a warning will be logged instead and the execution continues to enable compatibility with more systems.set-cookie
header was expected but not returned by a destination. Now, a warning will be logged instead and the execution continues to enable compatibility with more systems.@sap/cloud-sdk-generator
) did not compile when "strict": true
is set in the project's tsconfig.json
.August 29, 2019 - JSDoc API documentation | > Release blog
alwaysProvider
) or in the subscriber account (alwaysSubscriber
). You pass the strategy to use as part of the DestinationOptions
when retrieving a destination, if you do not want to use the default, subscriberFirst
. All strategies are available from an object helper DestinationSelectionStrategies
.August 15, 2019 - JSDoc API documentation | > Release blog
@sap/cloud-sdk-vdm-outbound-delivery-service
has been removed from the SAP API Business Hub and, as a consequence, from the SDK. Use @sap/cloud-sdk-vdm-outbound-delivery-v2-service
instead.@sap/cloud-sdk-vdm-*
), new operations in previously existing services, and new entity types. The SDK supports all OData services listed in the SAP API Business Hub for SAP S/4HANA Cloud.asChildOf()
method in CreateRequestBuilder
class.August 1, 2019 - JSDoc API documentation | > Release blog
useOrFetchDestination
or getDestination
explicitly, service bindings represented as destinations now take precedence over querying the destination service. If you have a service binding with the same name as a destination configured in the SAP Cloud Platform cockpit, this will lead to different behavior in your application, because of the newly introduced support for service bindings. Therefore we recommend using unique names across destinations and service bindings.HttpReponse
. Use HttpResponse
instead.DestinationNameAndJwt
as well as in useOrFetchDestination
and getDestination
.destinationForServiceBinding
that accepts the name of a service (as string) and tries to find a service binding with the given name and builds a Destination
for that service.HttpReponse
interface to HttpResponse
.July 18, 2019 - JSDoc API documentation | > Release blog
createTimeSheetDataFields
have been deprecated in favor of explicit builder functions available from separate namespaces such as TimeSheetDataFields.build
.executeHttpRequest
with a destination and the HTTP request to simply send an HTTP request using axios as HTTP request library.buildHttpRequest
to create an object with the minimal configuration for an HTTP request after resolving the destination and applying authentication. The returned object can be used as basis for an Axios request, or inspected manually.addDestinationToRequestConfig
merges a given HTTP request object with such a minimal configuration.retrieveJwt
to read authentication tokens in JWT format from a request.verifyJwt
to verify a JWT while decoding it.ResilienceOptions
when executing an OData request or when fetching the destination.serializeEntity
and deserializeEntity
for (de)serializing an OData entity according to the OData v2 standard.JSON.stringify
.Edm.Float
type for ABAP CDS compatibility.and
or or
functions resulted in an empty filter query option string.build
function, such as TimeSheetDataFields.build
.http-proxy-agent
dependency.July 4, 2019 - JSDoc API documentation | > Release blog
withCustomHeaders
function were not used
for fetching csrf tokens.?
as postfix.June 20, 2019 - JSDoc API documentation | > Release blog
withCustomHeaders
function are not used for fetching CSRF tokens. This has been fixed in version 1.5.0.
getDestinations
and getDestinationByName
in
env-destination-accessor
have been deprecated in favor of getDestinationsFromEnv
and getDestinationFromEnvByName
to better reflect their purpose. This has no effect on functionality.axios
to 0.19.0 (from 0.18.0).fast-xml-parser
and others in @sap/cloud-sdk-generator
.
June 6, 2019 - JSDoc API documentation | > Release blog
@sap/cloud-sdk-generator
to fast-xml-parser
is not properly defined, leading to errors such as Cannot find module 'fast-xml-parser'
when
calling the generator.
This has been fixed in version 1.4.2.@sap/cloud-sdk-generator
package.@sap/cloud-sdk-generator
, use the command
generate-odata-client
.
For example, npx generate-odata-client --help
will print the usage instructions and available
options.Protocol "http:" not
supported. Expected "https:"
.HTTPAgent
is imported to ensure module interoperability.May 23, 2019 - JSDoc API documentation | > Release blog
@sap/cloud-sdk-vdm-kanban-control-cycle-service
has been renamed to @sap/cloud-sdk-vdm-kanban-control-cycle-v2-service
to reflect that this service refers to version 2 of that API.@sap/cloud-sdk-vdm-change-master-service
has been renamed to
@sap/cloud-sdk-vdm-change-master-v2-service
and @sap/cloud-sdk-vdm-inbound-delivery-service
to @sap/cloud-sdk-vdm-inbound-delivery-v2-service
.
@sap/cloud-sdk-vdm-*
),
new operations in previously existing services, and new entity types. The SDK supports all OData
services listed in the SAP API
Business Hub for SAP S/4HANA Cloud.
getCustomField
for retrieving and setCustomField
for setting a
specific custom field on an entity, as well as getCustomFields
for retrieving all custom
fields and hasCustomField
for checking if a custom field exists.BusinessPartner
provide a method customField
to reference custom fields in select or filter query options.BusinessPartner.ALL_FIELDS
)
on each entity type for all fields of that entity. This representation can used in select query options to
retrieve all fields when also expanding navigation properties.Edm.DateTime
were not
serialized or deserialized correctly. Now, timezone offsets are correctly taken into account.May 9, 2019 - JSDoc API documentation | > Release blog
OnPremise
through the cloud
connector if an instance of the connectivity service is bound to the application. Only the necessary setup
is required as described in the documentation
for on-premise connectivity.mockAllTestDestinations
or mockTestDestination
.
Destinations defined in systems.json
together with a credentials.json
file for
credentials will be transparently mocked in all places that fetch
destinations by name.UnhandledPromiseRejections
.April 25, 2019 - JSDoc API documentation | > Release blog
getDestinationOptions
for accessing destinations with getDestination
and deprecate getDestinationOptions
.DestinationOrigin
, as it turned out to be unnecessary.cancel
in the material document service.ignoreVersionIdentifier
.
setVersionIdentifier
(example).
setVersionIdentifier
.
moment
,
BigNumber
) correctly.March 28, 2019 - JSDoc API documentation | > Release blog
@sap/cloud-sdk-vdm-business-partner-service
,
which contains all types and request builders representing the API.BusinessPartner.requestBuilder()
.
A request builder such as BusinessPartnerRequestBuilder
gives access to all operations supported on the entity type, for example, BusinessPartner.requestBuilder().getAll()
.
BusinessPartner
,
with all OData properties represented as properties such as BusinessPartner.lastName
.
BusinessPartner.builder()
.
BusinessPartner.LAST_NAME
for use in select
and filter
query options.Destination
,
possibly retrieved from the destination service on SAP Cloud Platform.
Destination
with URL and credentials when executing a OData VDM request.DestinationNameAndJwt
.
@sap/cloud-sdk-test-util
for loading
destinations of test systems and their credentials.