Adobe analytics API python Request date preset issue

Avatar

Avatar
Validate 1
Level 1
mithileshk26170
Level 1

Likes

0 likes

Total Posts

1 post

Correct reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
mithileshk26170
Level 1

Likes

0 likes

Total Posts

1 post

Correct reply

0 solutions
Top badges earned
Validate 1
View profile
mithileshk26170
Level 1

10-12-2018

Hi All,

I am using adobe analytics 2.0 API to automate reports using python.

Below is my python request code:-

report_def = ReportDefinition(metrics=['visits','Orders'],

                              dimensions=[{"id":"evar34","top": 500},{"id":"lasttouchchannel","top": 500}],

                              segemnts=[{"id":"s200000411_56a9c304e4b06f5aa20e9128"},{"id":"s200000411_57d1642be4b02a2dffb008a0"},{"id":"s200000411_57888bf3e4b0b892f6c5b4fe"}],

                              date_from='2018-12-01',

                             date_to= '2018-12-01',

                              granularity='day')

df1 = download_async(client, report_def, suite_ids=["clues-mapp","clues-msite", "clues-prod"])

Currently i need to manually type the date in the specified format.

Can I use preset dates like today, yesterday or 7 days ago ??

preset dates are available in both report builder and workspace.

Please help here.

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Contributor
MVP
AlexisCazes
MVP

Likes

187 likes

Total Posts

424 posts

Correct reply

198 solutions
Top badges earned
Contributor
Shape 1
Give Back 10
Give Back 5
Give Back 3
View profile

Avatar
Contributor
MVP
AlexisCazes
MVP

Likes

187 likes

Total Posts

424 posts

Correct reply

198 solutions
Top badges earned
Contributor
Shape 1
Give Back 10
Give Back 5
Give Back 3
View profile
AlexisCazes
MVP

11-12-2018

There is no preset.

You should use a logic in your code to build date on the fly and add it to your json request

Answers (0)