Skip to content

Minfraud report giving KeyError for "content-type" #99

@jeffrey04-laloka

Description

@jeffrey04-laloka

So after sending a report through .report(), your code have problem reading Content-Type from the response headers at line 621 (webservice.py)

{
    'Date': 'Tue, 29 Mar 2022 05:54:42 GMT',
    'Connection': 'keep-alive',
    'CF-Cache-Status': 'DYNAMIC',
    'Expect-CT': 'max-age=604800,
    report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"',
    'Server': 'cloudflare',
    'CF-RAY': '6f365a3378bc4834-SIN'
}

Am I calling the API incorrectly?

        client.report(
            {
                "ip_address": "xxx.xxx.xxx.xxx",
                "tag": "spam_or_abuse",
                "minfraud_id": str(minfraud_id_in_UUID)
            })

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions