प्रमाणीकरण
एपिआई कुञ्जीलाई बियरर टोकन (bearer token) को रूपमा पठाउनुहोस्। कुञ्जीसँग sites.manage अनुमति हुनुपर्छ; अनुमति नभएको कुञ्जीलाई 404 होइन, 403 मार्फत अस्वीकार गरिन्छ।
यो इन्डपोइन्टले कुनै संस्थाको आइडी लिँदैन। तपाईंको कुञ्जीले यस अन्तर्गत पर्ने संस्थालाई पहिल्यै पहिचान गर्छ, र प्रतिक्रिया त्यसैमा सीमित हुन्छ।
प्रयास गर्नुहोस्
कोणीय कोष्ठकभित्र भएका जुनसुकै कुरालाई आफ्नो मानहरूद्वारा बदल्नुहोस्, र मुख्य स्थानहोल्डरलाई तपाईंको ड्यासबोर्डको कुञ्जीद्वारा बदल्नुहोस्।
curl -X POST https://api.zinndigital.com/v1/sites/{siteId}/databases \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "name": <string> }'लगइन गर्नुभएको छ? तपाईंको ड्यासबोर्डमा रहेको API कन्सोलले तपाईंको वास्तविक संस्थाको आईडी र आफ्नै कुञ्जी भरिदिन्छ, र लाइभ API विरुद्ध अनुरोध चलाउँछ ताकि तपाईंले वास्तविक प्रतिक्रिया हेर्न सक्नुहोस्। यो एन्डपोइन्टलाई API कन्सोलमा खोल्नुहोस्
विवरणहरू
Creates a database and its user, and returns the generated password **exactly once**. The password is generated by this platform rather than chosen by the caller, because it is a machine-to-machine credential that nobody types and a human-chosen one is the weakest link in a stack the customer cannot patch. It is not stored in our records, not logged, and cannot be read back by any endpoint — a customer who loses it creates another database. The effective ceiling is applied before the vendor is called: a package type that does not permit databases, and an allowance that is already spent, are both `422` with a sentence the customer can act on. A name the package already carries is `409`. The vendor prefixes names per package, so the returned `name` is rarely the name that was asked for and the client must show the returned value. `404` for a site with no vendor hosting package. Requires `sites.manage`.
प्यारामिटरहरू
| नाम | प्रकार | आवश्यक | यो के हो |
|---|---|---|---|
siteId (path) | Uuid | हुन्छ | Site ID (UUIDv7). |
अनुरोध बडी
| नाम | प्रकार | आवश्यक | यो के हो |
|---|---|---|---|
name | string | हुन्छ | The name to ask for. The server's own name is returned in `SiteHostingDatabase.name` and may differ; there is deliberately no password field here, because the platform generates… |
प्रतिक्रिया
| नाम | प्रकार | आवश्यक | यो के हो |
|---|---|---|---|
database | SiteHostingDatabase | हुन्छ | The created database, exactly as `listSiteDatabases` will report it. |
password | string | हुन्छ | The generated password, shown once. Deliberately carries no example — a documented example of a credential field is the shape people copy. |
यो इन्डपोइन्टले फर्काउन सक्ने त्रुटिहरू
401 · 403 · 404 · 409 · 422 · 429 · 503