cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Invalid Effective date- SAP Subscription order update using API

praveen_tanwar
Participant
0 Kudos
445

Hi Experts,

I am trying to add subitem in existing subscription order.

Effective date of first item (parent item) is 2020-12-05 which is also the valid from date of subscription order.

Now I want to add subitem for parent item but I am getting below error:

Market is Europe and I am following below SAP Help:

Create a Subscription (POST on /subscriptions) - SAP Help Portal

It suggest that: The effectiveDate of all snapshots except the first one must be at the start of a day in the time zone of the market.

But did not get a clue what should be the correct date or time zone.

API: POST-/subscriptions/{id}/processes/productoptionsaddition

Please help in this case.

Thanks in Advance!


Regards,

Praveen Tanwar

Accepted Solutions (1)

Accepted Solutions (1)

stefan_kiene
Product and Topic Expert
Product and Topic Expert

Hi Parveen,

as of now, the effective dates of the snapshots need to be at the end of the day. As the timestamps
in Subscripton Billing are represented in UTC you need to pass the offset according to the time zone you are in.

  • Passing the time information manually
    Based on the time zone of your market fill the time considering the offset. E.g. for today (with daylight saving in winter) for a market in Germany you would need to pass
"effectiveDate": "2020-12-05T22:00:00.000Z"
  • Using the header parameter billing-sb-dates-in-market-timezone
    The APIs in the subscription service offer the http header parameter billing-sb-dates-in-market-timezone, which simplifys the calls in a way that you only need to provide the local date. The service will then automatically convert it into a timestamp using the correct offset to represent the beginning of the day as UTC timestamp.
    The content in the message body would then look like
"effectiveDate": "2020-12-06"

Both options will lead to exactly the same data in the subscription.

You may find a more detailed description of the header parameter billing-sb-dates-in-market-timezone at Subscription Billing API Guide - Subscriptions -> section "Timestamp Formats"

Best regards
Stefan

praveen_tanwar
Participant
0 Kudos

Thanks Stefen.

REgards,

Praveen Tanwar

Answers (0)