For Kinesis, it seems to be, that AWS organizes its folders on S3 like: "prefix/2019/02/09/13/kinesis-stream-name-2019-02-09-10-02-32-db1db7a9-c484-40d1-b7ec-7651a55e4677"

The date in the path is UTC-time, the date in the file name is the UTC-time of the first received byte in the Kinesis stream for the specific file. This is the default behavior, so it would be nice to implement it in localstack.
data = base64.b64decode(record['Data'])
                
                elif 'data' in record:
                    data = base64.b64decode(record['data'])
                body = json.loads(data)
                try:
                    es.create(index=es_index, doc_type=es_type, id=obj_id, body=body)
                except Exception as e:
                    LOG.error('Unable to put record to stream: %s %s' % (e, traceback.format_exc()))
                    raise e
        if 'S3DestinationDescription' in dest:
            s3_dest = dest['S3DestinationDescription']
            bucket = bucket_name(s3_dest['BucketARN'])
            prefix = s3_dest.get('Prefix', '')
            s3 = get_s3_client()
            for record in records:
                
                if 'Data' in record:
                    data = base64.b64decode(record['Data'])
                
                elif 'data' in record:
                    data = base64.b64decode(record['data'])
                obj_name = str(uuid.uuid4())
                obj_path = '%s%s%s' % (prefix, '' if prefix.endswith('/') else '/', obj_name)
                try:
                    s3.Object(bucket, obj_path).put(Body=data)
                except Exception as e:
                    LOG.error('Unable to put record to stream: %s %s' % (e, traceback.format_exc()))
                    raise e
def get_destination(stream_name, destination_id):