İstek
CreateLeaseRequest
Döndürülen değer
CreateLeaseResponse
Koşullar:
- lease_id, iş ortağı arka ucu tarafından oluşturulmalı ve CreateLeaseResponse'ta ayarlanmalıdır.
- lease_expiration_time, CreateLeaseResponse içinde ayarlanmalıdır.
- Kaynaklar alanı CreateLeaseRequest içinde belirtilmişse CreateLeaseResponse içinde ayarlanmalı ve CreateLeaseRequest ile eşleşmelidir.
- CreateLeaseResponse'taki diğer tüm alanlar ayarlanmalı ve CreateLeaseRequest ile eşleşmelidir.
Standart gRPC hata kodları
INVALID_ARGUMENT(geçersiz satıcı kimliği, hizmet kimliği, müşteri referansı veya zaman aralığı belirtimi)ALREADY_EXISTS(müşterinin zaten yer kiraladığı durumlarda)RESOURCE_EXHAUSTED(zaman aralığı kullanılamıyorsa)
// Request to create a [ext.maps.booking.partner.v0.Lease] for a slot in the // inventory. The expiration time in the returned Lease may be modified by the // backend, e.g. if the requested lease period is too long. message CreateLeaseRequest { option features.(pb.java).nest_in_file_class = YES; // The lease to be created with information about the appointment slot Lease lease = 1; } // Response for the [ext.maps.booking.partner.v0.CreateLease] RPC with the // created [ext.maps.booking.partner.v0.Lease] message CreateLeaseResponse { option features.(pb.java).nest_in_file_class = YES; // The created [ext.maps.booking.partner.v0.Lease] Lease lease = 1; }