Personnummer

Validate Swedish social security numbers. Build StatusCoverage Status

Installation

If available in Hex, the package can be installed by adding personnummer to your list of dependencies in mix.exs:

def deps do
  [
    {:personnummer, "~> 0.1.0"}
  ]
end

Example

iex> Personnummer.valid?(6403273813)
true
iex> Personnummer.valid?("19130401+2931")
true

Documentation can be generated with ExDoc and published on HexDocs. Once published, the docs can be found at https://hexdocs.pm/personnummer.