parent
b68667f253
commit
2c0007af12
@ -0,0 +1,33 @@
|
|||||||
|
package com.ruoyi.feishu;
|
||||||
|
|
||||||
|
import com.lark.oapi.Client;
|
||||||
|
import com.lark.oapi.core.request.RequestOptions;
|
||||||
|
import com.lark.oapi.service.bitable.v1.model.GetAppReq;
|
||||||
|
import com.lark.oapi.service.bitable.v1.model.GetAppResp;
|
||||||
|
import com.lark.oapi.service.bitable.v1.model.ListAppTableReq;
|
||||||
|
import com.lark.oapi.service.bitable.v1.model.ListAppTableResp;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
public class TestService {
|
||||||
|
|
||||||
|
Client client = Client.newBuilder("appId", "appSecret").build();
|
||||||
|
|
||||||
|
public void getBitTable() throws Exception {
|
||||||
|
GetAppReq req = GetAppReq.newBuilder().appToken("").build();
|
||||||
|
// RequestOptions options = RequestOptions.newBuilder()..build();
|
||||||
|
GetAppResp getAppResp = client.bitable().app().get(req);
|
||||||
|
getAppResp.getData().getApp();
|
||||||
|
}
|
||||||
|
public void getTables() throws Exception {
|
||||||
|
ListAppTableReq req = ListAppTableReq.newBuilder().appToken("").build();
|
||||||
|
// RequestOptions options = RequestOptions.newBuilder()..build();
|
||||||
|
ListAppTableResp list = client.bitable().appTable().list(req);
|
||||||
|
list.getData();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
Loading…
Reference in new issue