{"id":15372930,"url":"https://github.com/rs/domcheck","last_synced_at":"2025-08-24T10:15:10.269Z","repository":{"id":30487350,"uuid":"34041468","full_name":"rs/domcheck","owner":"rs","description":"A Python library to validate the ownership of a domain using different strategies","archived":false,"fork":false,"pushed_at":"2021-06-29T17:08:36.000Z","size":21,"stargazers_count":47,"open_issues_count":0,"forks_count":13,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-14T10:04:30.040Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rs.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-04-16T07:39:49.000Z","updated_at":"2025-04-07T18:53:15.000Z","dependencies_parsed_at":"2022-09-07T04:51:39.188Z","dependency_job_id":null,"html_url":"https://github.com/rs/domcheck","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rs%2Fdomcheck","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rs%2Fdomcheck/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rs%2Fdomcheck/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rs%2Fdomcheck/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rs","download_url":"https://codeload.github.com/rs/domcheck/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249061066,"owners_count":21206446,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-01T13:53:42.838Z","updated_at":"2025-04-15T11:31:53.184Z","avatar_url":"https://github.com/rs.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"Domcheck: Domain Ownership Validation\n=====================================\n\n.. image:: https://img.shields.io/pypi/v/domcheck.svg\n    :target: https://pypi.python.org/pypi/domcheck\n\n.. image:: https://travis-ci.org/rs/domcheck.svg?branch=master\n    :target: https://travis-ci.org/rs/domcheck\n\nThis Python library implements different strategies to validate the ownership of a domain name.\n\nAvailable strategies\n--------------------\n\nAll strategies takes 3 arguments: the domain to check, a static DNS safe ``prefix`` like \"yourservice-domain-verification\" and a randomly generated ``code``.\n\n- **DNS TXT record**: checks for the ``{prefix}-{code}`` string present in one of the ``TXT`` records on the domain name.\n- **DNS CNAME record**: checks for the existence of ``CNAME` record composed on the static ``{prefix}-{code}`` on the domain pointing to domain (usually yours) which the host is {prefix} (i.e.: {prefix}.yourdomain.com). NOTE: you may want to make sure that {prefix}.yourdomain.com resolves to something as some zone editors may check that.\n- **Meta Tag**: checks for the presence of a ``\u003cmeta name=\"{prefix}\" content=\"{code}\"\u003e`` tag in the ``\u003chead\u003e`` part of the domain's home page using either HTTP or HTTPs protocols.\n- **HTML File**: checks for the presence of a file named ``{code}.html`` at the root of the domain's website containing the string ``{prefix}={code}`` using either HTTP or HTTPs protocols.\n\nUsage Example\n-------------\n\nSimple usage will check the domain with all available strategies and return ``True`` if the validation passed:\n\n.. code-block:: python\n\n    import domcheck\n\n    domain = \"example.com\"\n    prefix = \"myservice-domain-verification\"\n    code = \"myserviceK2d8a0xdhh\"\n\n    if domcheck.check(domain, prefix, code):\n        print(\"This domain is verified\")\n\n\nYou may filter strategies by passing a coma separated list of strategies:\n\n.. code-block:: python\n\n    domcheck.check(domain, prefix, code, strategies=\"dns_txt,meta_tag\")\n\nInstallation\n------------\n\nTo install domcheck, simply:\n\n    $ pip install domcheck\n\nLicenses\n--------\n\nAll source code is licensed under the `MIT License \u003chttps://raw.githubusercontent.com/rs/domcheck/master/LICENSE\u003e`_.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frs%2Fdomcheck","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frs%2Fdomcheck","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frs%2Fdomcheck/lists"}