The earliest usage we've found in pulp fiction occurs in the March 27, 1921 issue of the Washington Post's "Magazine of Fiction," in a story entitled "The Fighting Fool" by Dane Coolidge.(See Examples)
In the classic 1939 movie Stagecoach: Curly, the sheriff, says, "I'm gonna ride shotgun," and John Wayne expresses surprise at seeing him in fact riding shotgun later. So we have references from pulp fiction and from the movies (but not from the Old West itself) using the term "riding shotgun" to refer to the stagecoach guard.
Stagecoach revived interest in westerns as a movie genre; in the 1950s they became a staple of television, too. Not surprisingly, catchphrases from westerns soon found their way into everyday speech.
So when does "riding shotgun" get transferred from stagecoach to automobile? The Dictionary of Americanisms (1951) doesn't mention "riding shotgun." We're not sure whether absence of a phrase is evidence, but it's certainly indicative. The first usage in print relating to automobiles, is - ready? - 1954. Dropping "riding" and using the simple "shotgun" (as in "I call shotgun") to mean the passenger seat comes in the early 60s.
Thus, the sequence seems to be that the usage "shotgun guard" on a stagecoach in the Old West (say, the 1880s) evolved to "riding shotgun" in popular fiction about the Old West in the 1920s and 1930s, from there made its way into movies and television, was applied to automobiles in the 1950s, and finally was shortened to "shotgun" in the 1960s.
The term "shotgun" is also used colloquially to indicate an act performed under duress, as though at gunpoint. In the 1880s we read of "elections held under the shotgun system" and in 1903 we find the first reference to "shotgun wedding," which suggests a pregnant bride and a nervous groom getting hitched at the insistence of a shotgun-wielding father. Today we use shotgun wedding figuratively, but one suspects it may have been meant literally in 1903.
Call shotgun in this case was seating in the couchguard seat with a shotgun.