Cyanamide

Cyanamide is an organic compound with the formula CN2H2. This white solid is widely used in agriculture and the production of pharmaceuticals and other organic compounds. It is also used as an alcohol-deterrent drug. The molecule features a nitrile group attached to an amino group. Derivatives of this compound are also referred to as cyanamides, the most common being calcium cyanamide (CaCN2). 
Tautomers and self-condensations.
Containing both a nucleophilic and electrophilic site within the same molecule, cyanamide undergoes various reactions with itself. Cyanamide exists as two tautomers, one with the connectivity N≡C–NH2 and the other with the formula HN=C=NH ("carbodiimide" tautomer). The N≡C–NH2 form dominates, but in a few reactions (e.g. silylation) the diimide form appears to be important. 
Cyanamide dimerizes to give 2-cyanoguanidine (dicyandiamide). This dimerization is disfavored by acids and is inhibited by low temperatures. The cyclic trimer is called melamine.
Production.
Cyanamide is produced by hydrolysis of calcium cyanamide, which in turn is prepared from calcium carbide via the Frank-Caro process.
The conversion is conducted on slurries.
Reactions and uses.
Cyanamide can be regarded as a functional single carbon fragment which can react as an electrophile or nucleophile. The main reaction exhibited by cyanamide involves additions of compounds containing an acidic proton. Water, hydrogen sulfide, and hydrogen selenide react with cyanamide to give urea, thiourea, and selenourea, respectively:
In this way, cyanamide behaves as a dehydration agent and thus can induce condensation reactions. Alcohols, thiols, and amines react analogously to give alkylisoureas, "pseudothioureas", and guanidines. The anti-ulcer drug cimetidine is generated using such reactivity. Related reactions exploit the bifunctionality of cyanamide to give heterocycles, and this latter reactivity is the basis of several pharmaceutical syntheses such as the aminopyrimidine imatinib) and agrichemicals Amitrol and hexazinone. The hair-loss treatment minoxidil and the anthelmintics albendazole, flubendazole, and mebendazole feature 2-aminoimidazole substructures derived from cyanamide. Cyanamide is also used in the synthesis of other pharmaceutical drugs including tirapazamine, etravirine, revaprazan, and dasantafil.
The cyanamide anion has the character of a pseudo chalcogen, cyanamide can therefore be regarded as analogue to water or hydrogen sulfide.
A convenient method for the preparation of secondary amines which are not contaminated with primary or tertiary amines is the reaction of cyanamide with alkyl halides to "N,N"-dialkylcyanamides which can easily be hydrolyzed to dialkylamines and then decarboxylated. Cyanamide adds itself in the presence of N-bromosuccinimide to olefinic double bonds. The addition product is converted by bases to N-Cyanaziridine, cyclized in the presence of acids to imidazolines, which can be further reacted to vicinal diamines by alkaline cleavage.
Cyanamide is also a versatile synthetic building block for heterocycles: it forms 2-aminobenzimidazole with 1,2-diaminobenzene and it forms with the readily available cyclic enamine 4-(1-cyclohexenyl)morpholine and with elemental sulfur a 2-aminothiazole in good yields.
Sodium dicyanamide is available in good yield and high purity from cyanamid and cyanogen chloride, which is suitable as an intermediate for the synthesis of active pharmaceutical ingredients. A guanidino group is introduced by reaction of cyanamide with sarcosine In the industrial synthesis of creatine:
This synthesis route mostly avoids problematic impurities like chloroacetic acid, iminodiacetic acid, or dihydrotriazine that occur in other routes. The physiological precursor guanidinoacetic is obtained analogously by reacting cyanamide with glycine.
Methods to stabilize cyanamidefmel make it available on an industrial scale. Due to the strong affinity towards self-condensation in alkaline media (see above) solutions of cyanamide are stabilized by the addition of 0.5 wt% of monosodium phosphate as buffer. Solid cyanamide is produced by careful evaporation of the solvent and subsequent addition of a hydrolysis-labile ester of formic acid. The ester absorbs traces of moisture (suppression of urea formation), neutralizes alkalinity (ammonia) and continually releases small amounts of formic acid.
Agricultural use.
Cyanamide, under the trade name Dormex, is a common agricultural rest-breaking agent applied in spring to stimulate uniform opening of buds, early foliation and bloom. Cyanamide can effectively compensate for the moderate lack of chilling units accumulated in the previous autumn and save the harvest that would otherwise be lost. It is particularly effective for woody plants such as berries, grapes, apples, peaches and kiwifruit. Overdosage, high concentration and error in timing of application can damage the buds (especially of peach trees).
A 50% aqueous solution of cyanamide is also used as a biocide (disinfectant) particularly in pig farming, because it effectively kills salmonella and shigella and fights flies in all stages of development.
Environmental aspects.
Cyanamide degrades via hydrolysis to urea, an excellent fertilizer. Fungi, like "Myrothecium verrucaria", accelerate this process utilizing the enzyme cyanamide hydratase.
Cyanamide functional group.
Cyanamide is the name for a functional group with the formula NCNRR' where R and R' can be a variety of groups. These compounds are called cyanamides. One example is naphthylcyanamide, C10H7N(H)CN Some cyanamides are prepared by alkylation of calcium cyanamide. Others, such as the naphthyl derivative, are produced indirectly.
Cyanamide in space.
Due to its high permanent dipole moment (i.e., 4.32 ± 0.08 D), cyanamide was detected by spectral emissions coming from the Sgr B2 molecular cloud (T < 100 K) through its microwave transitions as the first known interstellar molecule containing the NCN frame.
Safety.
It is used as an alcohol-deterrent drug in Canada, Europe, and Japan. 
Cyanamide has a modest toxicity in humans. Workplace exposure to hydrogen cyanamide sprays or exposure in people living in the vicinity of spraying have been reported as causing respiratory irritation, contact dermatitis, headache, and gastrointestinal symptoms of nausea, vomiting, or diarrhea.