Produkte
CRM Helpdesk Live-Chat Aufgabenverwaltung Projektmanagement VoIP Wissensdatenbank E-Mail E-Mail-Marketing Feedback Formulare und Umfragen
Mehr
Integrationen Funktionen Preise Blog Kontakt
Anmelden Kostenlos testen
Entwicklerdokumentation

Sugester API

Integrieren Sie Ihre Anwendung mit Sugester. REST API mit JSON - Kunden, Aufgaben, E-Mails, Deals, Formulare und mehr.

Vollständige Dokumentation auf GitHub

Wie Sie Ihre Anwendung oder Ihren Dienst mit sugester.com integrieren

Die API ermöglicht es Ihnen, Beiträge/Vorschläge/Fehler usw. aus anderen Systemen hinzuzufügen

Nach der Anmeldung bei Sugester finden Sie unter Einstellungen > API funktionierende Beispiele für Ihr Konto.

Inhaltsverzeichnis

API-Token

Der API-Autorisierungscode (API_TOKEN) sollte aus den Anwendungseinstellungen abgerufen werden: Einstellungen > API > API-Autorisierungscode. So müssen Sie in API-Aufrufen keinen Login/kein Passwort angeben.

Anwendungsbeispiele

Neuen Kunden hinzufügen

curl http://YOUR-PREFIX.sugester.pl/app/clients.json\
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_TOKEN",
"client": {
    "name":"client 1 from API",
    "email": "[email protected]",
    "note": "note 1"
  }
}'

Alle Kundendaten abrufen

curl http://YOUR-PREFIX.sugester.pl/app/clients.json?api_token=YOUR_API_TOKEN

Kundendaten abrufen

curl http://YOUR-PREFIX.sugester.pl/app/clients/1234.json?api_token=YOUR_API_TOKEN

Kundendaten aktualisieren

curl http://YOUR-PREFIX.sugester.pl/app/clients/1234.json\
     -X PUT \
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_TOKEN",
"client": {
    "note": "note from API"
  }
}'

Kunden löschen

curl -X DELETE  http://YOUR-PREFIX.sugester.pl/app/clients/12345.json?api_token=YOUR_API_TOKEN

Neue Aufgabe hinzufügen

curl http://YOUR-PREFIX.sugester.pl/app/posts.json \
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_TOKEN",
"post": {
    "title":"task title 1 from API",
    "content": "task content 1",
    "task_kind": "task",
    "client_id": null,
    "responsible_id": 1234
  }
}'

Alle Aufgabendaten abrufen (aus Helpdesk)

curl http://YOUR-PREFIX.sugester.pl/app.json?api_token=YOUR_API_TOKEN

Aufgabendaten abrufen

curl http://YOUR-PREFIX.sugester.pl/app/posts/1234.json?api_token=YOUR_API_TOKEN

Kommentar zur Aufgabe mit ID post_id hinzufügen

curl http://YOUR-PREFIX.sugester.pl/app/posts.json \
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_TOKEN",
"post": {
    "post_id": 123,
    "title":"comment for task 123",
    "content": "comment content 1",
    "task_kind": "comment",
    "client_id": null,
    "responsible_id": 1234
  }
}'

Neuen Deal hinzufügen

curl http://YOUR-PREFIX.sugester.pl/app/deals.json\
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_TOKEN",
"deal": {
    "name":"deal 1 from API",
    "description": "desc 1",
    "client_id": null
  }
}'

Deal aktualisieren

curl http://YOUR_PREFIX.sugester.pl/app/deals/1234.json\
    -X PUT \
    -H 'Accept: application/json' \
    -H 'Content-Type: application/json' \
    -d '
{
"api_token": "YOUR_API_TOKEN",
"deal": {
   "description": "new description from API"
 }
}'

Alle Deal-Daten abrufen

curl http://YOUR-PREFIX.sugester.pl/app/deals.json?api_token=YOUR_API_TOKEN

Deal-Daten abrufen

curl http://YOUR-PREFIX.sugester.pl/app/deals/1234.json?api_token=YOUR_API_TOKEN

Deal löschen

curl -X DELETE  http://YOUR-PREFIX.sugester.pl/app/deals/12345.json?api_token=YOUR_API_TOKEN

Kontakt hinzufügen

curl http://YOUR_PREFIX.sugester.pl/app/contacts.json\
    -H 'Accept: application/json' \
    -H 'Content-Type: application/json' \
    -d '
{
"api_token": "YOUR_API_TOKEN",
"contact": {
   "name":"contact 1 from API",
   "description": "new contact from API",
   "first_name": "John",
   "last_name": "Doe",
   "responsible_id": 1,
   "email": "[email protected]",
   "phone": "123456789"
 }
}'

Kontaktdaten abrufen

curl http://YOUR-PREFIX.sugester.pl/app/contacts/1234.json?api_token=YOUR_API_TOKEN

Kontaktdaten aktualisieren

curl http://YOUR_PREFIX.sugester.pl/app/contacts/1234.json\
    -X PUT \
    -H 'Accept: application/json' \
    -H 'Content-Type: application/json' \
    -d '
{
"api_token": "YOUR_API_TOKEN",
"contact": {
   "description": "new description from API"
 }
}'

Kontaktliste hinzufügen

curl https://YOUR_PREFIX.sugester.pl/app/contact_lists.json \
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_KEY",
"contact_list": {
    "name": "New contact list"
  }
}'

Kontaktlisten-Daten abrufen

curl https://YOUR_PREFIX.sugester.pl/app/contact_lists/10.json?api_token=YOUR_API_TOKEN

Kontaktlisten-Daten aktualisieren

curl https://YOUR_PREFIX.sugester.pl/app/contact_lists/10.json \
     -X PUT \
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_TOKEN",
"contact_list": {
    "name": "New contact list updated"
  }
}'

Post vom Typ "error" hinzufügen

curl http://your-prefix.sugester.pl/app/posts.json \
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "API_TOKEN",
"post": {
    "title":"post title2",
    "content": "post content 2",
    "kind": "error"
  }
}'

Neues Konto hinzufügen

curl http://YOUR-PREFIX.sugester.pl/app/account.json \
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_TOKEN",
"account": {
    "prefix":"sugester2",
    "initial_module": "crm",
    "from_partner": "partner1"
 },
"user": {
    "login": "login1",
    "email": "[email protected]",
    "password": "password1"
 }
}'

Integrationen

Neuen Kunden hinzufügen

curl https://YOUR_PREFIX.sugester.pl/app/clients.json \
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_TOKEN",
"client": {
    "name": "client 2 from External APP via API",
    "email": "[email protected]",
    "note": "note ext 2",
    "external_ids": {
        "myapp_client_id": "17"
    }
  }
}'

Neuen Deal hinzufügen

curl https://YOUR_PREFIX.sugester.pl/app/deals.json \
     -H 'Accept: application/json' \
     -H 'Content-Type: application/json' \
     -d '
{
"api_token": "YOUR_API_TOKEN",
"deal": {
    "name": "deal 2 from External APP via API",
    "description": "desc 2",
    "price": 117,
    "client": {
        "name": "client 2 from External APP via API",
        "email": "[email protected]",
        "external_ids": {
            "myapp_client_id": "17"
        }
    },
    "external_ids": {
        "myapp_invoice_id": "21"
    }
  }
}'

Spezifikation der Kundenfelder

{
	"id": Kunden-ID
	"name": Kundenname
	"tax_no": Steuernummer
	"post_code": Postleitzahl
	"city": Stadt
	"street": Straße
	"first_name": Vorname
	"country": Land
	"email": E-Mail
	"phone": Telefon
	"www": Website
	"fax": Fax
	"created_at": erstellt am
	"updated_at": aktualisiert am
	"street_no": Hausnummer
	"kind": Art (Käufer/Verkäufer)
	"bank": Bankname
	"bank_account": Bankkonto
	"bank_account_id":
	"shortcut": Namenskürzel
	"note": Notiz
	"last_name": Nachname
	"discount": Rabatt
	"payment_to_kind": Standard-Zahlungsziel der Rechnung
	"use_delivery_address": Lieferadresse aktiv
	"delivery_address": Lieferadresse
	"mobile_phone": Mobiltelefon
	"company": ist Firma
	"register_number": Registernummer
	"description": Beschreibung
	"project_id": Projekt-ID
	"contact_id": Haupt-Kontakt-ID
	"appendixes_count": Anzahl Anhänge
	"posts_count": Anzahl E-Mails/Aufgaben
	"contacts_count": Anzahl Kontakte
	"last_activity": letzte Aktivität
	"string1..10": benutzerdefinierte Felder
	"integer1..10": benutzerdefinierte Felder
	"decimal1..10": benutzerdefinierte Felder
	"checkbox1..10": benutzerdefinierte Felder
	"date1..10": benutzerdefinierte Felder
	"text1..10": benutzerdefinierte Felder
	"datetime1..10": benutzerdefinierte Felder
	"avatar_file_name": Avatar
	"avatar_content_type"
	"avatar_file_size"
	"avatar_updated_at"
	"status_id": Status-ID
	"category_id": Kategorie-ID
	"department_id": Abteilungs-ID
	"position": Position
	"creator_id": Ersteller-ID
	"updater_id": ID des letzten Bearbeiters
	"responsible_id": ID der verantwortlichen Person
	"province": Provinz/Bundesland
	"sensitive_data": sensible Daten verborgen
	"external_id": externe Kunden-ID
	"token": Kunden-Token
	"paid_from": bezahlt ab
	"paid_to": bezahlt bis
	"paid_total": Gesamtzahlungen vom Kunden
}

Spezifikation der Post-Felder (Aufgabe/Vorschlag/Meldung/E-Mail)

{
    "id": Post-ID
    "title": Titel
    "content": Inhalt
    "kind": Vorschlagstyp (suggestion, error, question, praise, private)
    "user_id": Benutzer-ID
    "points": Punktezahl
    "nick": Benutzer-Nick
    "votes_cache": Anzahl Stimmen
    "comments_cache": Anzahl Kommentare
    "forum_id": Forum-ID
    "category_id": Kategorie-ID
    "created_at": erstellt am
    "updated_at": zuletzt geändert am
    "ip": IP-Adresse
    "agent": Browser-Info
    "response": Hauptantwort
    "response_user_id": ID des Antwortenden
    "referrer": Referrer
    "responsible_id": ID der zugewiesenen Person
    "last_action_status": Status
    "email": Absender-E-Mail
    "uid": Benutzer-Token
    "spam_kind": Spam-Typ
    "answer": Antwort
    "answered": hat Antwort
    "duplicate_from_id": Duplikat-ID
    "abstract": Kurzfassung
    "status_id": Status-ID
    "view_count": Anzahl Aufrufe
    "tags": Tags
    "facebook_likes": Anzahl Facebook-Likes
    "min_votes_to_start": benötigte Stimmen zum Start
    "use_html": ist HTML
    "email_to": E-Mail an
    "email_cc": E-Mail CC
    "email_bcc": E-Mail BCC
    "spam_score": Spam-Score
    "spam_report": Spam-Info
    "closed": ist geschlossen (true/false)
    "scheduled_at": geplantes Datum
    "task_kind": Aufgabentyp (feedback, email, task, help, chat, phone, lead, error, idea)
    "priority": Priorität
    "title_note": null
    "user_spam_report": Spam-Meldung
    "client_id": Kunden-ID
    "project_id": Projekt-ID
    "help_link": Hilfelink-Schlüssel
    "help_content": Hilfeinhalt
    "post_id": übergeordnete Post-ID
    "www": Website des Verfassers
    "private": ist privat (true/false)
    "unread": ist ungelesen (true/false)
    "email_recipient": Empfänger (Helpdesk/Mail)
    "email_reply_to": Antwort an (Helpdesk/Mail)
}