I am writing a custom sync adapter following the example in the SDK sample, and things seem to be working well. I can sync back contacts from my server and have them appear in the Contacts app.
However, I am unable to add a contact directly to my server. Specifically, I want my sync adapter to appear as an option in the Spinner on the add contact screen, in addition to Google and Corporate, as shown in the screenshot. I couldn't find anything on the interwebs that talks about this.
Ok I figured it out. Turns out the contacts.xml file defining a
ContactsAccountType
that ships with the SDK sample is pretty bare bones. Fleshing it out a little makes my sync adapter appear in the Spinner (beginning with Android 4.0.3 according to this bug report).A sample showing all available fields is available here. I have copied it below for reference: