Created
July 9, 2021 09:29
-
-
Save mertyildiran/bbae35fe0e9de00872b9ae552109adf7 to your computer and use it in GitHub Desktop.
Catflix `discover_movie.json.j2`
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"page": 1, | |
"results": [{% for n in range(range(100) | random) %} | |
{ | |
"adult": {{ fake.boolean(chance_of_getting_true=25) | lower }}, | |
"backdrop_path": "/500/281/cat?random={{ fake.random_int(min=0, max=1000, step=1) }}", | |
"genre_ids": {{ ([request.queryString.with_genres | int] + fake.random_choices(elements=[12, 28, 53, 135, 956, 2786, 10752])) | unique | list | tojson }}, | |
"id": {{ fake.random_int(min=10000, max=50000, step=1) }}, | |
"original_language": "{{ fake.language_code() }}", | |
"original_title": "{{ fake.text(max_nb_chars=20)[:-1] | title }}", | |
"overview": "{{ fake.sentence(nb_words=10) }}", | |
"popularity": {{ random.float('0.0', '10000.0', 3) }}, | |
"poster_path": "/661/981/cat?random={{ fake.random_int(min=0, max=1000, step=1) }}", | |
"release_date": "{{ date.date('%Y-%m-%d') }}", | |
"title": "{{ fake.text(max_nb_chars=20)[:-1] | title }}", | |
"video": {{ fake.boolean(chance_of_getting_true=5) | lower }}, | |
"vote_average": {{ random.float('0.0', '10.0', 1) }}, | |
"vote_count": {{ fake.random_int(min=0, max=1000, step=1) }} | |
}{% if not loop.last %},{% endif %} | |
{% endfor %}], | |
"total_pages": {{ fake.random_int(min=500, max=2000, step=500) }}, | |
"total_results": {{ fake.random_int(min=10000, max=100000, step=500) }} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment