What kind of API's or frameworks are used to assign a note of music a value? Like how would an application like Shazzam take in a note from the microphone and know what to do with it? To me it's amazing a phones microphone and some nifty logic can compete with a tuner from a music shop!
Edit 1.
Interesting papers on the subject. Shazzam the music recognition app's software rests on the principle of Acoustic fingerprinting and a Fast Fourier Transform
Here's an example some similar code in practice
Acoustic fingerprinting algorithms do not try to analyze the music. That is, they do not convert audio from the microphone to notes. They are extracting some arbitrary features from the audio, that do not make much sense from musical theory perspective, but they are still useful for identifying music.
Normally, you start with a spectrogram. A spectrogram is analysis of frequencies as they change over time. That's common for almost all acoustic fingerprinting algorithms. The differ in what they do with the spectrogram and what kind of features do they extract from it. Some algorithms are looking for peaks in the spectrogram, some chunk it into regular intervals. The end goal is usually to generate a bunch of hashes that you can index and quickly search.
The original Shazam algorithm by Avery Li-Chun Wang is publicly available. You can find the details here.